1 // Copyright (C) 2007-2020 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 // SMESH SMESHGUI : GUI for SMESH component
24 // File : SMESHGUI_RevolutionDlg.h
25 // Author : Michael ZORIN, Open CASCADE S.A.S.
27 #ifndef SMESHGUI_REVOLUTIONDLG_H
28 #define SMESHGUI_REVOLUTIONDLG_H
31 #include "SMESH_SMESHGUI.hxx"
32 #include "SMESHGUI_PreviewDlg.h"
34 // SALOME GUI includes
35 #include <SALOME_InteractiveObject.hxx>
41 #include <SALOMEconfig.h>
42 #include CORBA_SERVER_HEADER(SMESH_Mesh)
44 class LightApp_SelectionMgr;
56 class SMESHGUI_3TypesSelector;
57 class SMESHGUI_FilterDlg;
58 class SMESHGUI_IdValidator;
59 class SMESHGUI_MeshEditPreview;
60 class SMESHGUI_SpinBox;
62 class SMESH_LogicalFilter;
64 class SalomeApp_IntSpinBox;
66 //=================================================================================
67 // class : SMESHGUI_RevolutionDlg
69 //=================================================================================
70 class SMESHGUI_EXPORT SMESHGUI_RevolutionDlg : public SMESHGUI_PreviewDlg
75 SMESHGUI_RevolutionDlg( SMESHGUI* );
76 ~SMESHGUI_RevolutionDlg();
79 enum {NONE_SELECT, POINT_SELECT, FACE_SELECT};
81 void Init( bool = true);
82 void enterEvent( QEvent* ); /* mouse enter the QWidget */
83 void keyPressEvent( QKeyEvent* );
84 int GetConstructorId();
89 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
90 SVTK_Selector* mySelector;
91 QWidget* myEditCurrentArgument; /* Current argument */
93 SMESHGUI_3TypesSelector* SelectorWdg;
94 QGroupBox* GroupButtons;
95 QPushButton* buttonOk;
96 QPushButton* buttonCancel;
97 QPushButton* buttonApply;
98 QPushButton* buttonHelp;
99 QGroupBox* GroupArguments;
100 QGroupBox* GroupAxis;
101 QCheckBox* MakeGroupsCheck;
102 QGroupBox* GroupAngleBox;
103 QButtonGroup* GroupAngle;
104 QRadioButton* RadioButton3;
105 QRadioButton* RadioButton4;
107 QLabel* TextLabelPoint;
108 QPushButton* SelectPointButton;
110 SMESHGUI_SpinBox* SpinBox_X;
112 SMESHGUI_SpinBox* SpinBox_Y;
114 SMESHGUI_SpinBox* SpinBox_Z;
115 QLabel* TextLabelVector;
116 QPushButton* SelectVectorButton;
118 SMESHGUI_SpinBox* SpinBox_DX;
120 SMESHGUI_SpinBox* SpinBox_DY;
122 SMESHGUI_SpinBox* SpinBox_DZ;
124 QLabel* TextLabelAngle;
125 SMESHGUI_SpinBox* SpinBox_Angle;
126 QLabel* TextLabelNbSteps;
127 SalomeApp_IntSpinBox* SpinBox_NbSteps;
128 QLabel* TextLabelTolerance;
129 SMESHGUI_SpinBox* SpinBox_Tolerance;
131 QMenu* SelectVectorMenu;
132 QMap<QAction*,int> myMenuActions;
133 int myVectorDefinition;
136 QString myHelpFileName;
139 virtual void onDisplaySimulation( bool );
140 virtual void reject();
143 void CheckIsEnable();
147 void SetEditCurrentArgument();
148 void SelectionIntoArgument();
149 void DeactivateActiveDialog();
150 void ActivateThisDialog();
151 void onAngleTextChange( const QString& );
152 void onSelectVectorMenu( QAction* );
153 void onSelectVectorButton();
158 #endif // SMESHGUI_REVOLUTIONDLG_H