GlobeEngine
VisibleLabelsDialog.h
Go to the documentation of this file.
1 #ifndef ExoViewer_VisibleLabelsDialog_h
2 #define ExoViewer_VisibleLabelsDialog_h
3 
4 #include "OpenGL_Includes.h"
5 #include <QDialog>
6 #include <QTreeWidget>
7 #include <QTreeWidgetItem>
8 #include <QVBoxLayout>
9 
10 #include <QDialogButtonBox>
11 #include <qcheckbox.h>
12 #include <qpushbutton.h>
13 #include <QLineEdit>
14 #include <qlabel.h>
15 #include <qcolordialog.h>
16 
17 namespace geExoViewer {
18  class VisibleLabelsDialog : public QDialog
19  {
20  Q_OBJECT
21 
22  public:
23  VisibleLabelsDialog(std::vector<bool> _initialValues, std::vector<int> _initialValuesInt, std::vector<QColor> _initialValuesColors, QWidget * parent = 0, Qt::WindowFlags f = 0);
25 
26 
27  bool getStarLabel();
28  bool getPlanetLabel();
29  bool getMoonLabel();
30  bool getSmallBodyLabel();
31  bool getSystemLabel();
32  bool getSelectedLabel();
33 
34  int getStarSize();
35  int getPlanetSize();
36  int getMoonSize();
37  int getSmallBodySize();
38  int getSystemSize();
39 
40  QColor getStarColor();
41  QColor getPlanetColor();
42  QColor getMoonColor();
43  QColor getSmallBodyColor();
44  QColor getSystemColor();
45  QColor getSelectedColor();
46 
47 
48  signals:
50 
51  private:
52  QTreeWidget* systemList;
53  QTreeWidget* typeList;
54 
55  QVBoxLayout* layout;
56 
57 
58  QCheckBox* star_label;
59  QCheckBox* planet_label;
60  QCheckBox* moon_label;
61  QCheckBox* smallBody_label;
62  QCheckBox* system_label;
63  QCheckBox* selected_label;
64 
65  QSlider* starSizeSlider;
66  QLineEdit* starSizeEdit;
67  QSlider* planetSizeSlider;
68  QLineEdit* planetSizeEdit;
69  QSlider* moonSizeSlider;
70  QLineEdit* moonSizeEdit;
71  QSlider* smallBodySizeSlider;
72  QLineEdit* smallBodySizeEdit;
73  QSlider* systemSizeSlider;
74  QLineEdit* systemSizeEdit;
75 
76  QColorDialog* starColorDialogO;
77  QPushButton* starColorbutton;
78  QColorDialog* planetColorDialogO;
79  QPushButton* planetColorbutton;
80  QColorDialog* moonColorDialogO;
81  QPushButton* moonColorbutton;
82  QColorDialog* smallBodyColorDialogO;
83  QPushButton* smallBodyColorbutton;
84  QColorDialog* systemColorDialogO;
85  QPushButton* systemColorbutton;
86  QColorDialog* selectedColorDialogO;
87  QPushButton* selectedColorbutton;
88 
89 
90  bool isNumber(std::string c);
91  QString getStyleSheetString(QColor col);
92 
93  private slots:
94  void accept();
95  void selectAll();
96  void deselectAll();
97 
98  void starColorDialog();
99  void starColorChanged();
100  void planetColorDialog();
101  void planetColorChanged();
102  void moonColorDialog();
103  void moonColorChanged();
104  void smallBodyColorDialog();
105  void smallBodyColorChanged();
106  void systemColorDialog();
107  void systemColorChanged();
108  void selectedColorDialog();
109  void selectedColorChanged();
110 
111  void setStarSize(int s);
112  void setStarSize(QString _s);
113  void setPlanetSize(int s);
114  void setPlanetSize(QString _s);
115  void setMoonSize(int s);
116  void setMoonSize(QString _s);
117  void setSmallBodySize(int s);
118  void setSmallBodySize(QString _s);
119  void setSystemSize(int s);
120  void setSystemSize(QString _s);
121 
122  void modifyVisiblity();
123  };
124 }
125 #endif
bool getMoonLabel()
Definition: VisibleLabelsDialog.cpp:420
QColor getSelectedColor()
Definition: VisibleLabelsDialog.cpp:464
QColor getSystemColor()
Definition: VisibleLabelsDialog.cpp:461
int getStarSize()
Definition: VisibleLabelsDialog.cpp:433
bool getSystemLabel()
Definition: VisibleLabelsDialog.cpp:426
int getPlanetSize()
Definition: VisibleLabelsDialog.cpp:436
bool getSmallBodyLabel()
Definition: VisibleLabelsDialog.cpp:423
bool getStarLabel()
Definition: VisibleLabelsDialog.cpp:414
int getSmallBodySize()
Definition: VisibleLabelsDialog.cpp:442
VisibleLabelsDialog(std::vector< bool > _initialValues, std::vector< int > _initialValuesInt, std::vector< QColor > _initialValuesColors, QWidget *parent=0, Qt::WindowFlags f=0)
Definition: VisibleLabelsDialog.cpp:4
QColor getSmallBodyColor()
Definition: VisibleLabelsDialog.cpp:458
QColor getPlanetColor()
Definition: VisibleLabelsDialog.cpp:452
QColor getMoonColor()
Definition: VisibleLabelsDialog.cpp:455
QColor getStarColor()
Definition: VisibleLabelsDialog.cpp:449
Definition: VisibleLabelsDialog.h:18
~VisibleLabelsDialog()
Definition: VisibleLabelsDialog.cpp:256
bool getSelectedLabel()
Definition: VisibleLabelsDialog.cpp:429
bool getPlanetLabel()
Definition: VisibleLabelsDialog.cpp:417
int getSystemSize()
Definition: VisibleLabelsDialog.cpp:445
int getMoonSize()
Definition: VisibleLabelsDialog.cpp:439
Definition: BodySelectionDialog.h:12