]> git.lyx.org Git - features.git/blob - src/frontends/qt4/GuiBox.h
GuiBox: fix bug 3242 http://bugzilla.lyx.org/show_bug.cgi?id=3242:
[features.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
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 "ControlBox.h"
18 #include "ui_BoxUi.h"
19
20 #include <vector>
21
22 namespace lyx {
23 namespace frontend {
24
25 class GuiBoxDialog : public GuiDialog, public Ui::BoxUi
26 {
27         Q_OBJECT
28
29 public:
30         GuiBoxDialog(LyXView & lv);
31
32 private Q_SLOTS:
33         void change_adaptor();
34         void innerBoxChanged(const QString &);
35         void typeChanged(int);
36         void heightChecked(int);
37         void restoreClicked();
38
39 private:
40         void closeEvent(QCloseEvent * e);
41
42         /// parent controller
43         ControlBox & controller();
44         /// add and remove special lengths
45         void setSpecial(bool ibox);
46         /// only show valid inner box items
47         void setInnerType(bool frameless, int i);
48
49         /// Apply changes
50         void applyView();
51         /// update
52         void updateContents();
53
54         ///
55         std::vector<std::string> ids_;
56         ///
57         std::vector<docstring> gui_names_;
58         ///
59         std::vector<std::string> ids_spec_;
60         ///
61         std::vector<docstring> gui_names_spec_;
62 };
63
64 } // namespace frontend
65 } // namespace lyx
66
67 #endif // GUIBOX_H