2 #ifndef DIALOGBOX_CLIPPING_H
3 #define DIALOGBOX_CLIPPING_H
5 #include "QtxDblSpinBox.h"
12 #include <vtkSmartPointer.h>
29 class SalomeApp_SelectionMgr;
38 typedef vtkSmartPointer<OrientedPlane> TVTKPlane;
39 typedef std::vector<TVTKPlane> TPlanes;
40 enum Orientation {XY, YZ, ZX};
44 //=================================================================================
45 // class : VisuGUI_ClippingDlg
47 //=================================================================================
48 class VisuGUI_ClippingDlg : public QDialog
53 VisuGUI_ClippingDlg( VisuGUI* theModule,
58 float getDistance() { return (float)SpinBoxDistance->value(); }
59 void setDistance(const float theDistance) { SpinBoxDistance->setValue(theDistance); }
60 double getRotation1() { return SpinBoxRot1->value(); }
61 double getRotation2() { return SpinBoxRot2->value(); }
62 void setRotation(const double theRot1, const double theRot2);
65 ~VisuGUI_ClippingDlg();
69 SalomeApp_SelectionMgr* mySelectionMgr;
72 VISU::Prs3d_i * myPrs3d;
73 VISU::TPlanes myPlanes;
75 QComboBox* ComboBoxPlanes;
76 QPushButton* buttonNew;
77 QPushButton* buttonDelete;
79 QLabel* TextLabelOrientation;
80 QLabel* TextLabelDistance;
81 QLabel* TextLabelRot1;
82 QLabel* TextLabelRot2;
86 QComboBox* ComboBoxOrientation;
87 QtxDblSpinBox* SpinBoxDistance;
88 QtxDblSpinBox* SpinBoxRot1;
89 QtxDblSpinBox* SpinBoxRot2;
91 QWidget* WidgetIJKTab;
92 QHButtonGroup* ButtonGroupIJKAxis;
93 QLabel* TextLabelIJKIndex;
94 QSpinBox* SpinBoxIJKIndex;
95 QCheckBox* CheckBoxIJKPlaneReverse;
97 QCheckBox* PreviewCheckBox;
98 QCheckBox* AutoApplyCheckBox;
100 QPushButton* buttonOk;
101 QPushButton* buttonCancel;
102 QPushButton* buttonApply;
104 bool myIsSelectPlane;
107 QWidget* createParamsTab();
108 QWidget* createIJKParamsTab();
109 void setIJKByNonStructured();
110 bool isStructured() const;
114 void onSelectPlane(int theIndex);
116 void ClickOnDelete();
117 void onSelectOrientation(int theItem);
118 void SetCurrentPlaneParam();
119 void SetCurrentPlaneIJKParam();
120 void onIJKAxisChanged(int axis);
121 void onTabChanged(QWidget* newTab);
122 void onSelectionChanged();
123 void OnPreviewToggle(bool theIsToggled);
125 void ClickOnCancel();
129 #endif // DIALOGBOX_TRANSPARENCYDLG_H