Back to index

scribus-ng  1.3.4.dfsg+svn20071115
tabtools.h
Go to the documentation of this file.
00001 /*
00002 For general Scribus (>=1.3.2) copyright and licensing information please refer
00003 to the COPYING file provided with the program. Following this notice may exist
00004 a copyright and/or license notice that predates the release of Scribus 1.3.2
00005 for which a new license (GPL+exception) is in place.
00006 */
00007 #ifndef TABTOOLS_H
00008 #define TABTOOLS_H
00009 
00010 #include <qvariant.h>
00011 #include <qwidget.h>
00012 #include <qlayout.h>
00013 #include <qlabel.h>
00014 #include <qtoolbutton.h>
00015 #include <qbuttongroup.h>
00016 #include <qcombobox.h>
00017 #include <qcheckbox.h>
00018 #include <qradiobutton.h>
00019 #include <qwidgetstack.h>
00020 
00021 #include "scribusapi.h"
00022 
00023 class QGroupBox;
00024 class LinkButton;
00025 class QSpinBox;
00026 class FontCombo;
00027 class PolygonWidget;
00028 class ArrowChooser;
00029 class MSpinBox;
00030 class LineCombo;
00031 class ScribusDoc;
00032 class ColorCombo;
00033 
00034 
00039 class SCRIBUS_API TabTools : public QWidget
00040 {
00041        Q_OBJECT
00042 
00043 public:
00044        TabTools( QWidget* parent, struct toolPrefs *prefsData, int unitIndex, ScribusDoc* doc);
00045        ~TabTools() {};
00046 
00047        void restoreDefaults(struct toolPrefs *prefsData, int unitIndex);
00048 
00054        void enableFontPreview(bool state);
00055 
00056        void unitChange(QString unit, int docUnitIndex, int decimals, double invUnitConversion);
00057 
00058        QButtonGroup* buttonGroupTools;
00059        QToolButton* toolShape;
00060        QToolButton* toolPoly;
00061        QToolButton* toolImage;
00062        QToolButton* toolText;
00063        QToolButton* toolLine;
00064        QToolButton* toolZoom;
00065        QToolButton* toolMisc;
00066        QWidgetStack* subStackTools;
00067        QWidget* subTabText;
00068        QLabel* textHeadLine;
00069        QLabel* textLabel3b;
00070        QLabel* textLabel3b2;
00071        QLabel* textLabel3b2t;
00072        QLabel* textLabel3b2t2;
00073        QLabel* textLabel3bT;
00074        QLabel* textLabel3bTL;
00075        QLabel* textLabel1b;
00076        QLabel* textLabel2b;
00077        QLabel* textLabel4b;
00078        QSpinBox* columnsText;
00079        QLabel* previewText;
00080        FontCombo* fontComboText;
00081        QComboBox* sizeComboText;
00082        ColorCombo* colorComboText;
00083        ColorCombo* colorComboStrokeText;
00084        ColorCombo* colorComboTextBackground;
00085        ColorCombo* colorComboTextLine;
00086        QSpinBox* shadingText;
00087        QSpinBox* shadingTextStroke;
00088        QSpinBox* shadingTextBack;
00089        QSpinBox* shadingTextLine;
00090        QLabel* textLabelTS;
00091        QLabel* textLabelTSS;
00092        QLabel* textLabelTSB;
00093        QLabel* textLabelTSL;
00094        QComboBox* tabFillCombo;
00095        QLabel* textLabel5b;
00096        MSpinBox* gapText;
00097        MSpinBox* gapTab;
00098        QWidget* subTabShape;
00099        QLabel* shapeHeadLine;
00100        QLabel* textLabel9b;
00101        QLabel* textLabel10b;
00102        MSpinBox* lineWidthShape;
00103        QLabel* textLabel12b;
00104        QLabel* textLabel11b;
00105        LineCombo* comboStyleShape;
00106        QSpinBox* shadingFillShape;
00107        ColorCombo* comboFillShape;
00108        QSpinBox* shadingLineShape;
00109        QLabel* textLabel7b;
00110        ColorCombo* colorComboLineShape;
00111        QLabel* textLabel8b;
00112        QWidget* subTabLine;
00113        QLabel* lineHeadLine;
00114        MSpinBox* lineWidthLine;
00115        QSpinBox* shadingLine;
00116        ColorCombo* colorComboLine;
00117        QLabel* textLabel13b;
00118        QLabel* textLabel14b;
00119        QLabel* textLabel15b;
00120        QLabel* textLabel16b;
00121        LineCombo* comboStyleLine;
00122        QWidget* subTabImage;
00123        QLabel* imageHeadLine;
00124        ColorCombo* comboFillImage;
00125        QLabel* textLabel19b;
00126        QSpinBox* shadingFillImage;
00127        QLabel* textLabel20b;
00128        QButtonGroup* buttonGroup3;
00129        QLabel* textLabel17b;
00130        QLabel* textLabel18b;
00131        QSpinBox* scalingHorizontal;
00132        QSpinBox* scalingVertical;
00133        LinkButton* chainButton;
00134        QButtonGroup* buttonGroup5;
00135        QCheckBox* checkRatioImage;
00136        QCheckBox* embeddedPath;
00137        QButtonGroup* buttonGroupRes;
00138        QRadioButton* checkFullRes;
00139        QRadioButton* checkNormalRes;
00140        QRadioButton* checkHalfRes;
00141        QWidget* subTabPolygon;
00142        QLabel* polygonHeadLine;
00143        PolygonWidget* polyWidget;
00144        QWidget* subTabZoom;
00145        QLabel* zoomHeadLine;
00146        QLabel* textLabel21b;
00147        QSpinBox* minimumZoom;
00148        QLabel* textLabel22b;
00149        QLabel* textLabel23b;
00150        QSpinBox* maximumZoom;
00151        QSpinBox* zoomStep;
00152        ArrowChooser* startArrow;
00153        ArrowChooser* endArrow;
00154        QLabel* startArrowText;
00155        QLabel* endArrowText;
00156        QLabel* arrowText;
00157        QWidget* subTabGeneral;
00158        QLabel* generalHeadLine;
00159        QGroupBox* genDispBox;
00160        QLabel* genText1;
00161        QLabel* genText2;
00162        MSpinBox* genDispX;
00163        MSpinBox* genDispY;
00164        QGroupBox* genRotBox;
00165        QLabel* genText3;
00166        QLabel* genText4;
00167        MSpinBox* genRot;
00168 
00169 protected slots:
00174        virtual void toggleChain();
00179        virtual void hChange();
00184        virtual void vChange();
00185        virtual void changeImageScalingFree(bool);
00186        virtual void changeImageScalingRatio(bool);
00191        virtual void setSample();
00196        virtual void setTool();
00197        virtual void setFillChar(int act);
00198        virtual void setCustomFillChar(const QString &txt);
00199 
00200 protected:
00201        QHBoxLayout* tabToolsLayout;
00202        QVBoxLayout* buttonGroupToolsLayout;
00203        QGridLayout* subTabTextLayout;
00204        QGridLayout* subTabShapeLayout;
00205        QGridLayout* subTabLineLayout;
00206        QGridLayout* subTabImageLayout;
00207        QGridLayout* buttonGroup3Layout;
00208        QHBoxLayout* buttonGroup5Layout;
00209        QVBoxLayout* buttonGroupResLayout;
00210        QGridLayout* subTabPolygonLayout;
00211        QGridLayout* subTabZoomLayout;
00212        QGridLayout* subTabGeneralLayout;
00213        QGridLayout* subTabGeneralLayout2;
00214        QGridLayout* subTabGeneralLayout3;
00215        ScribusDoc* docu;
00216        double unitRatio;
00217        QString unit;
00218        int precision;
00219 
00222        bool fontPreview;
00223 
00224        void enableSignals(bool);
00225 };
00226 #endif