summaryrefslogtreecommitdiffabout
path: root/microkde/kdatetbl.h
authorzautrix <zautrix>2005-02-08 16:24:18 (UTC)
committer zautrix <zautrix>2005-02-08 16:24:18 (UTC)
commit78c70cfbbe79243d8b0ec40f8f6438c99046e12b (patch) (unidiff)
tree382bc11ad3b56f72b8f84414e1da5e5ea871204b /microkde/kdatetbl.h
parent584ed7893497b2adad5ba6c3e914d90b76973b92 (diff)
downloadkdepimpi-78c70cfbbe79243d8b0ec40f8f6438c99046e12b.zip
kdepimpi-78c70cfbbe79243d8b0ec40f8f6438c99046e12b.tar.gz
kdepimpi-78c70cfbbe79243d8b0ec40f8f6438c99046e12b.tar.bz2
fix
Diffstat (limited to 'microkde/kdatetbl.h') (more/less context) (ignore whitespace changes)
-rw-r--r--microkde/kdatetbl.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/microkde/kdatetbl.h b/microkde/kdatetbl.h
index 2efa532..87808df 100644
--- a/microkde/kdatetbl.h
+++ b/microkde/kdatetbl.h
@@ -12,97 +12,97 @@
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details. 13 Library General Public License for more details.
14 14
15 You should have received a copy of the GNU Library General Public License 15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to 16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 17 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 Boston, MA 02111-1307, USA. 18 Boston, MA 02111-1307, USA.
19*/ 19*/
20#ifndef KDATETBL_H 20#ifndef KDATETBL_H
21#define KDATETBL_H 21#define KDATETBL_H
22 22
23#include <qvalidator.h> 23#include <qvalidator.h>
24#include <qgridview.h> 24#include <qgridview.h>
25#include <qlineedit.h> 25#include <qlineedit.h>
26#include <qdatetime.h> 26#include <qdatetime.h>
27 27
28/** 28/**
29* A table containing month names. It is used to pick a month directly. 29* A table containing month names. It is used to pick a month directly.
30* @internal 30* @internal
31* @version $Id$ 31* @version $Id$
32* @author Tim Gilman, Mirko Boehm 32* @author Tim Gilman, Mirko Boehm
33*/ 33*/
34class KDateInternalMonthPicker : public QGridView 34class KDateInternalMonthPicker : public QGridView
35{ 35{
36 Q_OBJECT 36 Q_OBJECT
37protected: 37protected:
38 /** 38 /**
39 * Store the month that has been clicked [1..12]. 39 * Store the month that has been clicked [1..12].
40 */ 40 */
41 int result; 41 int result;
42 /** 42 /**
43 * the cell under mouse cursor when LBM is pressed 43 * the cell under mouse cursor when LBM is pressed
44 */ 44 */
45 short int activeCol; 45 short int activeCol;
46 short int activeRow; 46 short int activeRow;
47 /** 47 /**
48 * Contains the largest rectangle needed by the month names. 48 * Contains the largest rectangle needed by the month names.
49 */ 49 */
50 QRect max; 50 QRect max;
51signals: 51signals:
52 /** 52 /**
53 * This is send from the mouse click event handler. 53 * This is send from the mouse click event handler.
54 */ 54 */
55 void closeMe(int); 55 void closeMe(int);
56public: 56public:
57 /** 57 /**
58 * The constructor. 58 * The constructor.
59 */ 59 */
60 KDateInternalMonthPicker(int fontsize, QWidget* parent, const char* name=0); 60 KDateInternalMonthPicker(QWidget* parent, const char* name=0);
61 /** 61 /**
62 * The size hint. 62 * The size hint.
63 */ 63 */
64 QSize sizeHint() const; 64 QSize sizeHint() const;
65 /** 65 /**
66 * Return the result. 0 means no selection (reject()), 1..12 are the 66 * Return the result. 0 means no selection (reject()), 1..12 are the
67 * months. 67 * months.
68 */ 68 */
69 int getResult() const; 69 int getResult() const;
70protected: 70protected:
71 /** 71 /**
72 * Set up the painter. 72 * Set up the painter.
73 */ 73 */
74 void setupPainter(QPainter *p); 74 void setupPainter(QPainter *p);
75 /** 75 /**
76 * The resize event. 76 * The resize event.
77 */ 77 */
78 void viewportResizeEvent(QResizeEvent*); 78 void viewportResizeEvent(QResizeEvent*);
79 /** 79 /**
80 * Paint a cell. This simply draws the month names in it. 80 * Paint a cell. This simply draws the month names in it.
81 */ 81 */
82 virtual void paintCell(QPainter* painter, int row, int col); 82 virtual void paintCell(QPainter* painter, int row, int col);
83 /** 83 /**
84 * Catch mouse click and move events to paint a rectangle around the item. 84 * Catch mouse click and move events to paint a rectangle around the item.
85 */ 85 */
86 void contentsMousePressEvent(QMouseEvent *e); 86 void contentsMousePressEvent(QMouseEvent *e);
87 void contentsMouseMoveEvent(QMouseEvent *e); 87 void contentsMouseMoveEvent(QMouseEvent *e);
88 /** 88 /**
89 * Emit monthSelected(int) when a cell has been released. 89 * Emit monthSelected(int) when a cell has been released.
90 */ 90 */
91 void contentsMouseReleaseEvent(QMouseEvent *e); 91 void contentsMouseReleaseEvent(QMouseEvent *e);
92 92
93private: 93private:
94 class KDateInternalMonthPrivate; 94 class KDateInternalMonthPrivate;
95 KDateInternalMonthPrivate *d; 95 KDateInternalMonthPrivate *d;
96}; 96};
97 97
98/** Year selection widget. 98/** Year selection widget.
99* @internal 99* @internal
100* @version $Id$ 100* @version $Id$
101* @author Tim Gilman, Mirko Boehm 101* @author Tim Gilman, Mirko Boehm
102*/ 102*/
103class KDateInternalYearSelector : public QLineEdit 103class KDateInternalYearSelector : public QLineEdit
104{ 104{
105 Q_OBJECT 105 Q_OBJECT
106protected: 106protected:
107 QIntValidator *val; 107 QIntValidator *val;
108 int result; 108 int result;
@@ -288,85 +288,85 @@ protected:
288 /** 288 /**
289 * Save the size of the largest used cell content. 289 * Save the size of the largest used cell content.
290 */ 290 */
291 QRect maxCell; 291 QRect maxCell;
292signals: 292signals:
293 /** 293 /**
294 * The selected date changed. 294 * The selected date changed.
295 */ 295 */
296 void dateChanged(QDate); 296 void dateChanged(QDate);
297 /** 297 /**
298 * A date has been selected by clicking on the table. 298 * A date has been selected by clicking on the table.
299 */ 299 */
300 void tableClicked(); 300 void tableClicked();
301 301
302protected: 302protected:
303 virtual void virtual_hook( int id, void* data ); 303 virtual void virtual_hook( int id, void* data );
304private: 304private:
305 class KDateTablePrivate; 305 class KDateTablePrivate;
306 KDateTablePrivate *d; 306 KDateTablePrivate *d;
307}; 307};
308 308
309#endif // KDATETBL_H 309#endif // KDATETBL_H
310class KDateInternalWeekPicker : public QGridView 310class KDateInternalWeekPicker : public QGridView
311{ 311{
312 Q_OBJECT 312 Q_OBJECT
313protected: 313protected:
314 /** 314 /**
315 * Store the month that has been clicked [1..12]. 315 * Store the month that has been clicked [1..12].
316 */ 316 */
317 int result; 317 int result;
318 /** 318 /**
319 * the cell under mouse cursor when LBM is pressed 319 * the cell under mouse cursor when LBM is pressed
320 */ 320 */
321 short int activeCol; 321 short int activeCol;
322 short int activeRow; 322 short int activeRow;
323 /** 323 /**
324 * Contains the largest rectangle needed by the month names. 324 * Contains the largest rectangle needed by the month names.
325 */ 325 */
326 QRect max; 326 QRect max;
327signals: 327signals:
328 /** 328 /**
329 * This is send from the mouse click event handler. 329 * This is send from the mouse click event handler.
330 */ 330 */
331 void closeMe(int); 331 void closeMe(int);
332public: 332public:
333 /** 333 /**
334 * The constructor. 334 * The constructor.
335 */ 335 */
336 KDateInternalWeekPicker(int fontsize, QWidget* parent, const char* name=0); 336 KDateInternalWeekPicker(QWidget* parent, const char* name=0);
337 /** 337 /**
338 * The size hint. 338 * The size hint.
339 */ 339 */
340 QSize sizeHint() const; 340 QSize sizeHint() const;
341 /** 341 /**
342 * Return the result. 0 means no selection (reject()), 1..12 are the 342 * Return the result. 0 means no selection (reject()), 1..12 are the
343 * months. 343 * months.
344 */ 344 */
345 int getResult() const; 345 int getResult() const;
346protected: 346protected:
347 /** 347 /**
348 * Set up the painter. 348 * Set up the painter.
349 */ 349 */
350 void setupPainter(QPainter *p); 350 void setupPainter(QPainter *p);
351 /** 351 /**
352 * The resize event. 352 * The resize event.
353 */ 353 */
354 void viewportResizeEvent(QResizeEvent*); 354 void viewportResizeEvent(QResizeEvent*);
355 /** 355 /**
356 * Paint a cell. This simply draws the month names in it. 356 * Paint a cell. This simply draws the month names in it.
357 */ 357 */
358 virtual void paintCell(QPainter* painter, int row, int col); 358 virtual void paintCell(QPainter* painter, int row, int col);
359 /** 359 /**
360 * Catch mouse click and move events to paint a rectangle around the item. 360 * Catch mouse click and move events to paint a rectangle around the item.
361 */ 361 */
362 void contentsMousePressEvent(QMouseEvent *e); 362 void contentsMousePressEvent(QMouseEvent *e);
363 void contentsMouseMoveEvent(QMouseEvent *e); 363 void contentsMouseMoveEvent(QMouseEvent *e);
364 /** 364 /**
365 * Emit monthSelected(int) when a cell has been released. 365 * Emit monthSelected(int) when a cell has been released.
366 */ 366 */
367 void contentsMouseReleaseEvent(QMouseEvent *e); 367 void contentsMouseReleaseEvent(QMouseEvent *e);
368 368
369private: 369private:
370 class KDateInternalMonthPrivate; 370 class KDateInternalMonthPrivate;
371 KDateInternalMonthPrivate *d; 371 KDateInternalMonthPrivate *d;
372}; 372};