1 // SMESH SMESHGUI : GUI for SMESH component
3 // Copyright (C) 2003 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.
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
24 // File : SMESHGUI_ExtrusionAlongPathDlg.h
25 // Author : Vadim SANDLER
29 #ifndef DIALOGBOX_EXTRUSION_PATH_H
30 #define DIALOGBOX_EXTRUSION_PATH_H
32 #include "LightApp_SelectionMgr.h"
33 #include "SUIT_SelectionFilter.h"
50 class SMESHGUI_SpinBox;
51 class SVTK_ViewWindow;
56 #include <SALOMEconfig.h>
57 #include CORBA_SERVER_HEADER(SMESH_Mesh)
59 //=================================================================================
60 // class : SMESHGUI_ExtrusionAlongPathDlg
62 //=================================================================================
63 class SMESHGUI_ExtrusionAlongPathDlg : public QDialog
69 SetBusy (SMESHGUI_ExtrusionAlongPathDlg* _dlg) { myDlg = _dlg; myDlg->myBusy = true; }
70 ~SetBusy() { myDlg->myBusy = false; }
72 SMESHGUI_ExtrusionAlongPathDlg* myDlg;
77 SMESHGUI_ExtrusionAlongPathDlg (SMESHGUI*,
79 ~SMESHGUI_ExtrusionAlongPathDlg();
81 bool eventFilter (QObject* object, QEvent* event);
84 void Init (bool ResetControls = true);
85 void enterEvent (QEvent*); /* mouse enter the QWidget */
86 void keyPressEvent(QKeyEvent*);
87 int GetConstructorId();
88 void SetEditCurrentArgument (QToolButton* button);
90 SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
91 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
92 SVTK_Selector* mySelector;
94 QWidget* myEditCurrentArgument; /* Current argument */
97 SMESH::SMESH_Mesh_var myMesh;
98 SMESH_Actor* myMeshActor;
99 SMESH::SMESH_IDSource_var myIDSource;
100 SMESH::SMESH_Mesh_var myPathMesh;
101 GEOM::GEOM_Object_var myPathShape;
102 SUIT_SelectionFilter* myElementsFilter;
103 SUIT_SelectionFilter* myPathMeshFilter;
107 QButtonGroup* GroupConstructors;
108 QRadioButton* Elements1dRB;
109 QRadioButton* Elements2dRB;
111 QGroupBox* GroupArguments;
113 QToolButton* SelectElementsButton;
114 QLineEdit* ElementsLineEdit;
115 QCheckBox* MeshCheck;
118 QToolButton* SelectPathMeshButton;
119 QLineEdit* PathMeshLineEdit;
120 QLabel* PathShapeLab;
121 QToolButton* SelectPathShapeButton;
122 QLineEdit* PathShapeLineEdit;
123 QLabel* StartPointLab;
124 QToolButton* SelectStartPointButton;
125 QLineEdit* StartPointLineEdit;
126 QCheckBox* AnglesCheck;
127 QGroupBox* AnglesGrp;
128 QListBox* AnglesList;
129 QToolButton* AddAngleButton;
130 QToolButton* RemoveAngleButton;
131 SMESHGUI_SpinBox* AngleSpin;
132 QCheckBox* BasePointCheck;
133 QGroupBox* BasePointGrp;
134 QToolButton* SelectBasePointButton;
136 SMESHGUI_SpinBox* XSpin;
138 SMESHGUI_SpinBox* YSpin;
140 SMESHGUI_SpinBox* ZSpin;
142 QGroupBox* GroupButtons;
143 QPushButton* OkButton;
144 QPushButton* ApplyButton;
145 QPushButton* CloseButton;
146 QPushButton* HelpButton;
148 QString myHelpFileName;
154 void ConstructorsClicked (int);
158 void SetEditCurrentArgument();
159 void SelectionIntoArgument();
160 void DeactivateActiveDialog();
161 void ActivateThisDialog();
162 void onTextChange (const QString&);
164 void onAnglesCheck();
165 void onBasePointCheck();
167 void OnAngleRemoved();
170 #endif // DIALOGBOX_EXTRUSION_PATH_H