]> git.lyx.org Git - features.git/blob - src/frontends/qt4/InsetDialog.h
Inset::validateModifyArgument(): new virtual interface for using LFUN_INSET_MODIFY.
[features.git] / src / frontends / qt4 / InsetDialog.h
1 // -*- C++ -*-\r
2 /**\r
3  * \file InsetDialog.h\r
4  * This file is part of LyX, the document processor.\r
5  * Licence details can be found in the file COPYING.\r
6  *\r
7  * \author Abdelrazak Younes\r
8  *\r
9  * Full author contact details are available in file CREDITS.\r
10  */\r
11 \r
12 #ifndef INSET_DIALOG_H\r
13 #define INSET_DIALOG_H\r
14 \r
15 #include "DialogView.h"\r
16 \r
17 namespace lyx {\r
18 \r
19 class Inset;\r
20 \r
21 namespace frontend {\r
22 \r
23 class InsetDialog : public DialogView\r
24 {\r
25         Q_OBJECT\r
26 \r
27 public:\r
28         InsetDialog(GuiView & lv, InsetCode code, \r
29                 QString const & name, QString const & title);\r
30 \r
31         /// \name DialogView inherited methods\r
32         //@{\r
33         void applyView();\r
34         void updateView();\r
35         void dispatchParams() {}\r
36         bool isBufferDependent() const { return true; }\r
37         bool canApply() const { return true; }\r
38         //@}\r
39 \r
40 protected Q_SLOTS:\r
41         void on_closePB_clicked();\r
42 \r
43 protected:\r
44         ///\r
45         virtual void paramsToDialog(Inset const *) = 0;\r
46         ///\r
47         virtual docstring dialogToParams() const = 0;\r
48         ///\r
49         InsetCode const code_;\r
50 };\r
51 \r
52 } // namespace frontend\r
53 } // namespace lyx\r
54 \r
55 #endif // INSET_DIALOG_H\r