Salome HOME
e46903a0595b007fceb8113536cfca9553c210f7
[modules/gui.git] / src / OCCViewer / OCCViewer_ClippingDlg.h
1 #ifndef OCCVIEWER_CLIPPINGDLG_H
2 #define OCCVIEWER_CLIPPINGDLG_H
3
4 #include "OCCViewer.h"
5
6 #include <qdialog.h>
7
8 #include <AIS_Plane.hxx>
9
10 class QGroupBox;
11 class QLabel;
12 class QPushButton;
13 class QComboBox;
14 class QCheckBox;
15 class QtxDblSpinBox;
16
17 class OCCViewer_ViewWindow;
18
19
20 //=================================================================================
21 // class    : OCCViewer_ClippingDlg
22 // purpose  :
23 //=================================================================================
24 class OCCViewer_ClippingDlg : public QDialog
25 {
26     Q_OBJECT
27     
28     public:
29     OCCViewer_ClippingDlg(OCCViewer_ViewWindow* , QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
30     ~OCCViewer_ClippingDlg();
31     
32 private :
33
34     virtual void closeEvent( QCloseEvent* e );
35     virtual void showEvent ( QShowEvent * );
36     virtual void hideEvent ( QHideEvent * );
37     void displayPreview();
38     void erasePreview();
39
40     bool isValid();
41      
42     QGroupBox* GroupPoint;
43     QLabel* TextLabelX;
44     QLabel* TextLabelY;
45     QLabel* TextLabelZ;
46     QtxDblSpinBox* SpinBox_X;
47     QtxDblSpinBox* SpinBox_Y;
48     QtxDblSpinBox* SpinBox_Z;
49     QPushButton* resetButton;
50     
51     QGroupBox* GroupDirection;
52     QLabel* TextLabelDx;
53     QLabel* TextLabelDy;
54     QLabel* TextLabelDz;
55     QtxDblSpinBox* SpinBox_Dx;
56     QtxDblSpinBox* SpinBox_Dy;
57     QtxDblSpinBox* SpinBox_Dz;
58     QPushButton* invertButton;
59     
60     QComboBox* DirectionCB;
61
62     QCheckBox* PreviewChB;
63
64     QPushButton*    buttonApply;
65     QPushButton*    buttonClose;
66     
67     OCCViewer_ViewWindow* myView;
68
69     Handle(AIS_Plane) myPreviewPlane;
70     
71     bool myBusy;
72     
73 private slots:
74   void ClickOnApply();
75   void ClickOnClose();
76
77   void onReset();
78   void onInvert();
79   void onModeChanged( int mode );
80   void onValueChanged();
81   void onPreview( bool on );
82 };
83
84 #endif // OCCVIEWER_CLIPPINGDLG_H