Databasehandlingdialogclasses  0.5.3
hk_kdequery.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_KDEQUERY_H
13 #define HK_KDEQUERY_H
14 
15 #include <qvariant.h>
16 #include <kparts/dockmainwindow.h>
17 #include <kparts/partmanager.h>
18 
19 #include "hk_kdequerypartwidget.h"
20 
21 #include "hk_dsquery.h"
22 #include "hk_datasource.h"
23 #include "hk_database.h"
24 class QVBoxLayout;
25 class QHBoxLayout;
26 class QGridLayout;
27 class QButtonGroup;
28 class QTable;
29 class QToolButton;
30 class QMultiLineEdit;
31 
44 class hk_kdequery : public KParts::DockMainWindow ,public hk_dsquery
45 {
46  Q_OBJECT
47 
48  public:
49  hk_kdequery(QWidget* w=0,const char* n=0,WFlags f=0);
50 virtual ~hk_kdequery();
51  virtual bool set_mode(enum_mode s);
55  bool in_designmode(void) const ;
56 
57 
61  void set_nodesignmode(bool n);
62  virtual void set_datasource(hk_datasource*);
63 
64  bool save_query(const hk_string& n="",bool ask=true);
65  bool load_query(void);
66  void set_autoclose(bool c);
67  signals:
68  void signal_closed(QWidget*);
69 
70  public slots:
71  void close_query(void);
72  protected slots:
73  void part_removed(void);
74  void createGUI (KParts::Part *part);
75 
76 
77  protected:
78  virtual void closeEvent ( QCloseEvent* e);
79  virtual void before_source_vanishes(void);
80 
81 
82  private:
83  void set_caption(void);
84  KParts::ReadWritePart* p_part;
85  KParts::PartManager* p_partmanager;
86  hk_kdequerypartwidget* p_query;
87  KAction * p_closeaction;
88 
89 
90 };
91 #endif
void set_nodesignmode(bool n)
Definition: hk_kdequery.cpp:133
KDE high level widget to define queries and see the result.
Definition: hk_kdequerypartwidget.h:52
bool in_designmode(void) const
Definition: hk_kdequery.cpp:217
KDE high level widget to define queries and see the result.
Definition: hk_kdequery.h:44