PCB Environment 2

Loading...
Searching...
No Matches
ViewTab.hpp
1#ifndef GYM_PCB_UI_VIEWTAB_H
2#define GYM_PCB_UI_VIEWTAB_H
3
4#include "Py.hpp"
5#include <QWidget>
6#include <QHBoxLayout>
7 class QCheckBox;
8 class QLabel;
9 class QPushButton;
10 class QSlider;
11 class QVBoxLayout;
12
13 class GLWidget;
14 class ViewTab;
15
16 class LayerAlphaSlider : public QHBoxLayout
17{
18 Q_OBJECT
19 public:
20 LayerAlphaSlider(ViewTab *, int layerIndex);
21 ~LayerAlphaSlider();
22 int getLayer() const { return mZ; }
23 QSlider *getSlider() const { return mSlider; }
24 private:
25 QSlider *mSlider;
26 const int mZ;
27};
28
29 class ViewTab : public QWidget
30{
31 Q_OBJECT
32 public:
33 bool init(GLWidget *);
34 void setNumLayers(GLWidget *, uint);
35 public slots:
36 void onLayerAlphaSlider(int layerIndex, int value);
37 void onSlowdownSlider(int);
38 uint slowdownToSliderPosition(uint us) const;
39 void onSave();
40 private:
41 QPushButton *mZDirection;
42 QPushButton *mScreenshot;
43 QPushButton *mResetZoom;
44 QCheckBox *mSelectionLayers;
45 QCheckBox *mSelectionType;
46 QCheckBox *mShowGridLines;
47 QCheckBox *mShowGridPoints;
48 QCheckBox *mShowRatsNest;
49 QCheckBox *mLimitRatsNest;
50 QCheckBox *mShowTriangles;
51 QCheckBox *mShowAStar;
52 QVBoxLayout *mAlphaSliders;
53 QSlider *mSlowdown;
54 QLabel *mSlowdownLabel;
55 private:
56 GLWidget *WGL{0};
57 private:
58 bool changeDirection();
59};
60
61#endif // GYM_PCB_UI_VIEWTAB_H
GLWidget
Definition GLWidget.hpp:34
ViewTab
Definition ViewTab.hpp:30