Databasehandlingdialogclasses  0.5.3
hk_kdegrid.h
1 // ****************************************************************************
2 // copyright (c) 2000-2005 Horst Knorr <hk_classes@knoda.org>
3 // This file is part of the hk_kdeclasses library.
4 // This file may be distributed and/or modified under the terms of the
5 // GNU Library Public License version 2 as published by the Free Software
6 // Foundation and appearing in the file LGPL included in the
7 // packaging of this file.
8 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
9 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
10 // ****************************************************************************
11 
12 #ifndef HK_KDEGRID
13 #define HK_KDEGRID
14 #include <hk_class.h>
15 #include <qlayout.h>
16 #include <qpushbutton.h>
17 #include <qheader.h>
18 //#include <qstatusbar.h>
19 #include <qwidget.h>
20 #include <qframe.h>
21 #include <qlabel.h>
22 
23 #include "hk_dsgrid.h"
24 
25 class hk_kderowselector;
26 class hk_kdesimpleform;
27 class hk_kdefinddialog;
28 class hk_kdegridpart;
29 class hk_kdesimplegrid;
30 
45 class hk_kdegrid :public QFrame, public hk_dsgrid
46 {
47  friend class hk_kdegridpart;
48  friend class hk_kdesimplegrid;
49  Q_OBJECT
50  public:
51  hk_kdegrid(QWidget* w=0,const char* n=0,WFlags f=0,hk_kdesimpleform* form=NULL);
52  virtual ~hk_kdegrid();
56  void set_datasource(hk_datasource* d);
60  hk_kdesimplegrid* simplegrid(void){return p_grid;}
61  hk_kdegridpart* part(void){return p_part;}
62 virtual void show_widget(void);
63 virtual void hide_widget(void);
64 virtual bool close_widget(void);
65 
66 
67  public slots:
68 // void datasource_enables(void);
69 // void datasource_disables(void);
70  void find_clicked(void);
71  void find_next(void);
72  void findargument_changed(void);
73  void print_grid(void);
74 
75  protected:
76  virtual bool widget_specific_coordinates(unsigned int px,unsigned int py,unsigned int pwidth,unsigned int pheight);
77  virtual void widget_specific_presentationdatasource(long p);
78  virtual void widget_specific_enable_disable(void);
79  virtual void widget_specific_font_changed(void);
80 
81  virtual void resizeEvent (QResizeEvent *);
82  virtual void moveEvent ( QMoveEvent * ) ;
83  virtual void before_row_change(void);
84  virtual void widget_specific_backgroundcolour_changed(const hk_colour&);
85  virtual void widget_specific_foregroundcolour_changed(const hk_colour&);
86  virtual void widget_specific_columns_created(void);
87  void widget_specific_rowheight_changes(void);
88  virtual bool presentationmode_changed(void);
89 
90  private:
91  hk_kdefinddialog* p_finddialog;
92  bool p_findfirstview;
93  QHBoxLayout* hbottomlayout;
94  QHBoxLayout* hdatalayout;
95  QHBoxLayout* htoplayout;
96  QVBoxLayout* vbasiclayout;
97  hk_kdesimplegrid* p_grid;
98  hk_kderowselector* selector;
99  QLabel* statusbar;
100  void reposition(void);
101  hk_kdegridpart* p_part;
102 }
103 
104 
105 ;
106 
111 #endif
KDE Widget to select a specific row.
Definition: hk_kderowselector.h:32
hk_kdesimplegrid * simplegrid(void)
Definition: hk_kdegrid.h:60
void print_grid(void)
Definition: hk_kdesimplegrid.cpp:1361
KDE Widget to display forms.
Definition: hk_kdesimpleform.h:41
KDE Widget to display data in a grid.
Definition: hk_kdesimplegrid.h:47
void set_datasource(hk_datasource *d)
Definition: hk_kdegrid.cpp:112
Definition: hk_kdefinddialog.h:17
shows data in a grid without columnheaders.
Definition: hk_kdegrid.h:45