r18299 by jghali - fix code indentation issues
scribus-commit
scribus-commit at lists.scribus.net
Sat Jun 1 23:40:21 UTC 2013
Author: jghali
Date: Sat Jun 1 23:40:21 2013
New Revision: 18299
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=18299
Log:
fix code indentation issues
Modified:
trunk/Scribus/scribus/plugins/gettext/xtgim/fontselectdialog.cpp
trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.cpp
trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.h
Modified: trunk/Scribus/scribus/plugins/gettext/xtgim/fontselectdialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=18299&path=/trunk/Scribus/scribus/plugins/gettext/xtgim/fontselectdialog.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/gettext/xtgim/fontselectdialog.cpp (original)
+++ trunk/Scribus/scribus/plugins/gettext/xtgim/fontselectdialog.cpp Sat Jun 1 23:40:21 2013
@@ -34,40 +34,40 @@
setWindowIcon(QIcon(loadIcon ( "AppIcon.png" )));
setWindowTitle( tr("Select Alternate Font"));
- resize(370, 83);
- layoutWidget = new QWidget(this);
- layoutWidget->setGeometry(QRect(10, 10, 350, 63));
- verticalLayout_2 = new QVBoxLayout(layoutWidget);
- verticalLayout_2->setContentsMargins(0, 0, 0, 0);
- horizontalLayout_2 = new QHBoxLayout();
- label = new QLabel(layoutWidget);
+ resize(370, 83);
+ layoutWidget = new QWidget(this);
+ layoutWidget->setGeometry(QRect(10, 10, 350, 63));
+ verticalLayout_2 = new QVBoxLayout(layoutWidget);
+ verticalLayout_2->setContentsMargins(0, 0, 0, 0);
+ horizontalLayout_2 = new QHBoxLayout();
+ label = new QLabel(layoutWidget);
label->setText( tr("Font") );
- label->setMinimumSize(QSize(61, 0));
+ label->setMinimumSize(QSize(61, 0));
- horizontalLayout_2->addWidget(label);
+ horizontalLayout_2->addWidget(label);
- fontList = new QComboBox(layoutWidget);
- fontList->setMinimumSize(QSize(281, 0));
+ fontList = new QComboBox(layoutWidget);
+ fontList->setMinimumSize(QSize(281, 0));
fontList->addItems(list);
- horizontalLayout_2->addWidget(fontList);
+ horizontalLayout_2->addWidget(fontList);
- verticalLayout_2->addLayout(horizontalLayout_2);
+ verticalLayout_2->addLayout(horizontalLayout_2);
- horizontalLayout_3 = new QHBoxLayout();
- horizontalSpacer = new QSpacerItem(128, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
+ horizontalLayout_3 = new QHBoxLayout();
+ horizontalSpacer = new QSpacerItem(128, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
- horizontalLayout_3->addItem(horizontalSpacer);
+ horizontalLayout_3->addItem(horizontalSpacer);
- okButton = new QPushButton("OK",layoutWidget);
- okButton->setEnabled(true);
- okButton->setMinimumSize(QSize(105, 0));
+ okButton = new QPushButton("OK",layoutWidget);
+ okButton->setEnabled(true);
+ okButton->setMinimumSize(QSize(105, 0));
- horizontalLayout_3->addWidget(okButton);
+ horizontalLayout_3->addWidget(okButton);
- verticalLayout_2->addLayout(horizontalLayout_3);
- label->setBuddy(fontList);
+ verticalLayout_2->addLayout(horizontalLayout_3);
+ label->setBuddy(fontList);
font = fontList->currentText();
connect(fontList, SIGNAL(activated(int)), this, SLOT(selectFont()));
Modified: trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=18299&path=/trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.cpp (original)
+++ trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.cpp Sat Jun 1 23:40:21 2013
@@ -34,7 +34,7 @@
class ScribusDoc;
-XtgScanner::XtgScanner ( QString documentName,TextWriter *wr,QString& buffer, bool textOnly, bool prefix)
+XtgScanner::XtgScanner (QString documentName, TextWriter *wr, QString& buffer, bool textOnly, bool prefix)
{
writer = wr;
docname = documentName;
@@ -322,15 +322,11 @@
QList<QString> List = ((*(doc->AllFonts)).keys());
QStringList filter = static_cast<QStringList>(List).filter(token);
if (!filter.empty())
- List = filter;
+ List = filter;
FontSelect *f = new FontSelect(static_cast<QStringList>(List));
if (f->exec())
- {
token = f->setFont();
- delete f;
- }
- else
- delete f;
+ delete f;
}
curFontUsed = (*(doc->AllFonts)).value(token);
/* Now we check whether isBold=true and isItalic=true. If yes, we will set those */
Modified: trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=18299&path=/trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.h
==============================================================================
--- trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.h (original)
+++ trunk/Scribus/scribus/plugins/gettext/xtgim/xtgscanner.h Sat Jun 1 23:40:21 2013
@@ -54,36 +54,36 @@
{
private:
/**
- \variable Variables based on which scanner works in different modes
- */
+ \variable Variables based on which scanner works in different modes
+ */
scannerMode Mode;
scannerMode prevMode;
- /**
- \variable Variables of the importer
- */
+ /**
+ \variable Variables of the importer
+ */
TextWriter* writer;
bool importTextOnly;
bool usePrefix;
- QString docname;
+ QString docname;
bool readProperties;
- /**
- \variable Flag variables used in the scanner
- */
+ /**
+ \variable Flag variables used in the scanner
+ */
bool newlineFlag;
bool xflag;
- bool isBold;
- bool isItalic;
- /**
- \variable Input Buffer to which properly encoded file is loaded
- */
+ bool isBold;
+ bool isItalic;
+ /**
+ \variable Input Buffer to which properly encoded file is loaded
+ */
QString input_Buffer;
- int top;
+ int top;
ScFace curFontUsed;
ScribusDoc* doc;
- /**
- \variable current Character and paragraph styles
- */
+ /**
+ \variable current Character and paragraph styles
+ */
CharStyle currentCharStyle;
ParagraphStyle currentParagraphStyle;
@@ -98,9 +98,7 @@
/** A QStringList to store the features of defined character Style and defined paragraph Style */
QStringList dcsFeatures;
- /**
- To store unsupported attributes
- */
+ /** To store unsupported attributes */
QStringList unSupported;
QStringList definedStyles;
QStringList definedCStyles;
@@ -109,25 +107,25 @@
*/
QString textToAppend;
QString token;
- QString sfcName; // Name of Style/Fontset/Color to be defined, hence named sfcName
+ QString sfcName; // Name of Style/Fontset/Color to be defined, hence named sfcName
QHash<QString,void (XtgScanner::*)(void)> tagModeHash;
QHash<QString,void (XtgScanner::*)(void)> textModeHash;
QHash<QString,void (XtgScanner::*)(void)> nameModeHash;
- QHash<int,QString> languages;
- QHash<int,QString> encodings;
+ QHash<int,QString> languages;
+ QHash<int,QString> encodings;
/** define variable will take the following values :
- \brief
- 0 Not a definition
+ \brief
+ 0 Not a definition
1 Character Stylesheet Definition
2 Paragraph Stylesheet Definition
- */
+ */
int define;
public:
- XtgScanner(QString documentName,TextWriter *wr,QString& buffer, bool textOnly, bool prefix);
- ~XtgScanner();
+ XtgScanner(QString documentName, TextWriter *wr, QString& buffer, bool textOnly, bool prefix);
+ ~XtgScanner();
/**
\brief initialise all hash functions with tokens and corresponding function pointers
@@ -165,26 +163,26 @@
\brief This function will return a token which is to be evaluated in parser. Each token will be available in the class member token as a QString.
*/
QString getToken();
- /**
- \brief Function to Slice the string so as to remove the inch character etc
- */
+ /**
+ \brief Function to Slice the string so as to remove the inch character etc
+ */
QString sliceString();
- /**
- \name applyFeature
- \brief Function to applyFeature to a character Style
- */
+ /**
+ \name applyFeature
+ \brief Function to applyFeature to a character Style
+ */
void applyFeature(const QString &feature);
- /**
- \brief Function which will empty the textToAppend variable by writing into text frame
- */
+ /**
+ \brief Function which will empty the textToAppend variable by writing into text frame
+ */
void flushText();
- /**
- \brief Function which returns the status of Style whether defined or not
- */
+ /**
+ \brief Function which returns the status of Style whether defined or not
+ */
bool styleStatus(QStringList &name,QString &sfcname);
- /**
- \brief Function which will show a message box if a Style "name" is not defined in the document
- */
+ /**
+ \brief Function which will show a message box if a Style "name" is not defined in the document
+ */
void showWarning(QString &name);
/** Set Functions for setting the styles */
@@ -230,14 +228,14 @@
void setHyphenation();
void setPRuleAbove();
void setPRuleBelow();
- void setDropCap();
+ void setDropCap();
void setKeepNextPar();
void setKeepTogether();
void setHangingCSet();
void setGlyph();
void setTranscodeSeq();
void setUnencodedGlyph();
- void xFlag();
+ void xFlag();
void definePStyles();
void defineCStyle();
void applyCStyle1();
@@ -250,9 +248,9 @@
void appendSpChar1();
void appendSpChar2();
void appendSpChar3();
- /**
- Functions used in textMode Hash
- */
+ /**
+ Functions used in textMode Hash
+ */
void defNewLine();
void defHardReturn();
void defFontSet();
@@ -265,7 +263,7 @@
protected:
- void (XtgScanner::*funPointer)(void);
+ void (XtgScanner::*funPointer)(void);
};
#endif
More information about the scribus-commit
mailing list