]> git.lyx.org Git - lyx.git/blob - src/frontends/qt4/GuiBox.h
do what the FIXME suggested
[lyx.git] / src / frontends / qt4 / GuiBox.h
1 // -*- C++ -*-
2 /**
3  * \file GuiBox.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Jürgen Spitzmüller
8  * \author Martin Vermeer (with useful hints from Angus Leeming)
9  *
10  * Full author contact details are available in file CREDITS.
11  */
12
13 #ifndef GUIBOX_H
14 #define GUIBOX_H
15
16 #include "GuiDialog.h"
17 #include "ui_BoxUi.h"
18 #include "insets/InsetBox.h"
19
20 #include <vector>
21
22
23 namespace lyx {
24 namespace frontend {
25
26 class GuiBox : public GuiDialog, public Ui::BoxUi
27 {
28         Q_OBJECT
29
30 public:
31         GuiBox(GuiView & lv);
32
33 private Q_SLOTS:
34         void change_adaptor();
35         void innerBoxChanged(const QString &);
36         void typeChanged(int);
37         void restoreClicked();
38         void pagebreakClicked();
39
40 private:
41         /// add and remove special lengths
42         void setSpecial(bool ibox);
43         /// only show valid inner box items
44         void setInnerType(bool frameless, int i);
45
46         /// Apply changes
47         void applyView();
48         /// update
49         void updateContents();
50
51         ///
52         bool initialiseParams(std::string const & data);
53         ///
54         void clearParams();
55         ///
56         void dispatchParams();
57         ///
58         bool isBufferDependent() const { return true; }
59
60         ///
61         std::vector<std::string> ids_;
62         ///
63         std::vector<docstring> gui_names_;
64         ///
65         std::vector<std::string> ids_spec_;
66         ///
67         std::vector<docstring> gui_names_spec_;
68
69         ///
70         InsetBoxParams params_;
71 };
72
73 } // namespace frontend
74 } // namespace lyx
75
76 #endif // GUIBOX_H