add more spacing
[personal-kdebase.git] / workspace / kwin / kcmkwin / kwinoptions / windows.h
blobd5197e1f986bfd66bb0d551e7706eb20ad8eccd8
1 /*
2 * windows.h
4 * Copyright (c) 1997 Patrick Dowler dowler@morgul.fsh.uvic.ca
5 * Copyright (c) 2001 Waldo Bastian bastian@kde.org
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 #ifndef KKWMWINDOWS_H
23 #define KKWMWINDOWS_H
25 #include <QWidget>
26 #include <kcmodule.h>
27 #include <config-workspace.h>
29 class QRadioButton;
30 class QCheckBox;
31 class QPushButton;
32 class QComboBox;
33 class QGroupBox;
34 class QLabel;
35 class QSlider;
36 class KButtonGroup;
37 class QSpinBox;
39 class KColorButton;
40 class KIntNumInput;
42 #define TRANSPARENT 0
43 #define OPAQUE 1
45 #define CLICK_TO_FOCUS 0
46 #define FOCUS_FOLLOW_MOUSE 1
48 #define TITLEBAR_PLAIN 0
49 #define TITLEBAR_SHADED 1
51 #define RESIZE_TRANSPARENT 0
52 #define RESIZE_OPAQUE 1
54 #define SMART_PLACEMENT 0
55 #define MAXIMIZING_PLACEMENT 1
56 #define CASCADE_PLACEMENT 2
57 #define RANDOM_PLACEMENT 3
58 #define CENTERED_PLACEMENT 4
59 #define ZEROCORNERED_PLACEMENT 5
60 #define INTERACTIVE_PLACEMENT 6
61 #define MANUAL_PLACEMENT 7
63 #define CLICK_TO_FOCUS 0
64 #define FOCUS_FOLLOWS_MOUSE 1
65 #define FOCUS_UNDER_MOUSE 2
66 #define FOCUS_STRICTLY_UNDER_MOUSE 3
68 class QSpinBox;
70 class KFocusConfig : public KCModule
72 Q_OBJECT
73 public:
74 KFocusConfig( bool _standAlone, KConfig *_config, const KComponentData &inst, QWidget *parent );
75 ~KFocusConfig();
77 void load();
78 void save();
79 void defaults();
81 private slots:
82 void setDelayFocusEnabled();
83 void focusPolicyChanged();
84 void autoRaiseOnTog(bool);//CT 23Oct1998
85 void delayFocusOnTog(bool);
86 void clickRaiseOnTog(bool);
87 void updateAltTabMode();
88 void updateActiveMouseScreen();
89 void changed() { emit KCModule::changed(true); }
92 private:
94 int getFocus( void );
95 int getAutoRaiseInterval( void );
96 int getDelayFocusInterval( void );
98 void setFocus(int);
99 void setAutoRaiseInterval(int);
100 void setAutoRaise(bool);
101 void setDelayFocusInterval(int);
102 void setDelayFocus(bool);
103 void setClickRaise(bool);
104 void setSeparateScreenFocus(bool);
105 void setActiveMouseScreen(bool);
106 void setAltTabMode(bool);
107 void setTraverseAll(bool);
108 void setRollOverDesktops(bool);
109 void setShowPopupinfo(bool);
111 void setFocusStealing( int );
112 QComboBox* focusStealing;
114 //QGroupBox *fcsBox;
115 QWidget* fcsBox;
116 QComboBox *focusCombo;
117 QLabel *autoRaiseOnLabel;
118 QCheckBox *autoRaiseOn;
119 QLabel *delayFocusOnLabel;
120 QCheckBox *delayFocusOn;
121 QCheckBox *clickRaiseOn;
122 KIntNumInput *autoRaise;
123 KIntNumInput *delayFocus;
124 QCheckBox *separateScreenFocus;
125 QCheckBox *activeMouseScreen;
127 KButtonGroup *kbdBox;
128 QCheckBox *altTabPopup;
129 QCheckBox *traverseAll;
130 QCheckBox *rollOverDesktops;
131 QCheckBox *showPopupinfo;
133 KConfig *config;
134 bool standAlone;
137 class KMovingConfig : public KCModule
139 Q_OBJECT
140 public:
141 KMovingConfig( bool _standAlone, KConfig *config, const KComponentData &inst, QWidget *parent );
142 ~KMovingConfig();
144 void load();
145 void save();
146 void defaults();
148 private slots:
149 void changed() { emit KCModule::changed(true); }
150 void slotBrdrSnapChanged( int );
151 void slotWndwSnapChanged( int );
152 void slotCntrSnapChanged( int );
154 private:
155 int getMove( void );
156 int getResizeOpaque ( void );
157 bool getGeometryTip( void ); //KS
159 void setMove(int);
160 void setResizeOpaque(int);
161 void setGeometryTip(bool); //KS
162 void setMoveResizeMaximized(bool);
164 KButtonGroup *windowsBox;
165 QCheckBox *opaque;
166 QCheckBox *resizeOpaqueOn;
167 QCheckBox *geometryTipOn;
168 QCheckBox *moveResizeMaximized;
170 KConfig *config;
171 bool standAlone;
173 int getBorderSnapZone();
174 void setBorderSnapZone( int );
175 int getWindowSnapZone();
176 void setWindowSnapZone( int );
177 int getCenterSnapZone();
178 void setCenterSnapZone( int );
180 KButtonGroup *MagicBox;
181 QLabel *BrdrSnapLabel, *WndwSnapLabel, *CntrSnapLabel;
182 KIntNumInput *BrdrSnap, *WndwSnap, *CntrSnap;
183 QCheckBox *OverlapSnap;
187 class KAdvancedConfig : public KCModule
189 Q_OBJECT
190 public:
191 KAdvancedConfig( bool _standAlone, KConfig *config, const KComponentData &inst, QWidget *parent );
192 ~KAdvancedConfig();
194 void load();
195 void save();
196 void defaults();
198 private slots:
199 void shadeHoverChanged(bool);
201 //copied from kcontrol/konq/kwindesktop, aleXXX
202 void setEBorders();
204 void changed() { emit KCModule::changed(true); }
206 private:
208 int getShadeHoverInterval (void );
209 void setShadeHover(bool);
210 void setShadeHoverInterval(int);
212 KButtonGroup *shBox;
213 QCheckBox *shadeHoverOn;
214 QLabel *shadeHoverLabel;
215 KIntNumInput *shadeHover;
217 KConfig *config;
218 bool standAlone;
220 int getElectricBorders( void );
221 int getElectricBorderDelay();
222 void setElectricBorders( int );
223 void setElectricBorderDelay( int );
225 KButtonGroup *electricBox;
226 QRadioButton *active_disable;
227 QRadioButton *active_move;
228 QRadioButton *active_always;
229 QLabel *delaysLabel;
230 KIntNumInput *delays;
232 void setHideUtilityWindowsForInactive( bool );
233 QCheckBox* hideUtilityWindowsForInactive;
235 int getPlacement( void ); //CT
236 void setPlacement(int); //CT
237 QComboBox *placementCombo;
240 #endif // KKWMWINDOWS_H