karbon
vconfiguredlg.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef __VCONFIGUREDLG_H__
00021 #define __VCONFIGUREDLG_H__
00022
00023
00024 #include <kdialogbase.h>
00025
00026 class KarbonView;
00027 class KConfig;
00028 class KIntNumInput;
00029 class KColorButton;
00030 class KoUnitDoubleSpinBox;
00031 class QCheckBox;
00032 class QComboBox;
00033
00034 class VConfigInterfacePage : public QObject
00035 {
00036 Q_OBJECT
00037
00038 public:
00039 VConfigInterfacePage(
00040 KarbonView* view, QVBox *box = 0L, char* name = 0L );
00041
00042 void apply();
00043
00044 public slots:
00045 void slotDefault();
00046
00047 private:
00048 KarbonView* m_view;
00049 KConfig* m_config;
00050
00051 KIntNumInput* m_recentFiles;
00052 int m_oldRecentFiles;
00053
00054 QCheckBox* m_showStatusBar;
00055
00056 KIntNumInput* m_copyOffset;
00057 int m_oldCopyOffset;
00058
00059 KIntNumInput* m_dockerFontSize;
00060 int m_oldDockerFontSize;
00061 };
00062
00063
00064 class VConfigMiscPage : public QObject
00065 {
00066 Q_OBJECT
00067
00068 public:
00069 VConfigMiscPage(
00070 KarbonView* view, QVBox* box, char* name = 0L );
00071
00072 void apply();
00073
00074 signals:
00075 void unitChanged( int );
00076
00077 public slots:
00078 void slotDefault();
00079
00080 private:
00081 KarbonView* m_view;
00082 KConfig* m_config;
00083
00084 KIntNumInput* m_undoRedo;
00085 int m_oldUndoRedo;
00086 int m_oldUnit;
00087 QComboBox *m_unit;
00088 };
00089
00090 class VConfigDefaultPage : public QObject
00091 {
00092 Q_OBJECT
00093
00094 public:
00095 VConfigDefaultPage(
00096 KarbonView* view, QVBox* box, char* name = 0L );
00097
00098 void apply();
00099
00100 public slots:
00101 void slotDefault();
00102
00103 private:
00104 KarbonView* m_view;
00105 KConfig* m_config;
00106
00107 KIntNumInput* m_autoSave;
00108 int m_oldAutoSave;
00109 QCheckBox *m_createBackupFile;
00110 bool m_oldBackupFile;
00111 QCheckBox *m_saveAsPath;
00112 bool m_oldSaveAsPath;
00113 };
00114
00115 class VConfigGridPage : public QObject
00116 {
00117 Q_OBJECT
00118
00119 public:
00120 VConfigGridPage(
00121 KarbonView* view, QVBox* box, char* name = 0L );
00122
00123 void apply();
00124
00125 public slots:
00126 void slotDefault();
00127 void slotUnitChanged( int );
00128
00129 protected slots:
00130 void setMaxHorizSnap( double v );
00131 void setMaxVertSnap( double v );
00132
00133 private:
00134 KarbonView* m_view;
00135 KoUnitDoubleSpinBox* m_spaceHorizUSpin;
00136 KoUnitDoubleSpinBox* m_spaceVertUSpin;
00137 KoUnitDoubleSpinBox* m_snapHorizUSpin;
00138 KoUnitDoubleSpinBox* m_snapVertUSpin;
00139 QCheckBox* m_gridChBox;
00140 QCheckBox* m_snapChBox;
00141 KColorButton* m_gridColorBtn;
00142 };
00143
00144 class VConfigureDlg : public KDialogBase
00145 {
00146 Q_OBJECT
00147
00148 public:
00149 VConfigureDlg( KarbonView* parent );
00150
00151 public slots:
00152 void slotApply();
00153 void slotDefault();
00154
00155 private:
00156 VConfigInterfacePage* m_interfacePage;
00157 VConfigMiscPage* m_miscPage;
00158 VConfigGridPage* m_gridPage;
00159 VConfigDefaultPage* m_defaultDocPage;
00160 };
00161
00162 #endif
00163
|