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.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
24 // File : SMESHGUI_ExtrusionAlongPathDlg.h
25 // Author : Vadim SANDLER
29 #ifndef DIALOGBOX_EXTRUSION_PATH_H
30 #define DIALOGBOX_EXTRUSION_PATH_H
32 #include "SALOME_Selection.h"
33 #include "SMESH_LogicalFilter.hxx"
34 #include "SMESH_TypeFilter.hxx"
47 class SMESHGUI_SpinBox;
52 #include <SALOMEconfig.h>
53 #include CORBA_SERVER_HEADER(SMESH_Mesh)
55 //=================================================================================
56 // class : SMESHGUI_ExtrusionAlongPathDlg
58 //=================================================================================
59 class SMESHGUI_ExtrusionAlongPathDlg : public QDialog
65 SetBusy( SMESHGUI_ExtrusionAlongPathDlg* _dlg ) { myDlg = _dlg; myDlg->myBusy = true; }
66 ~SetBusy() { myDlg->myBusy = false; }
68 SMESHGUI_ExtrusionAlongPathDlg* myDlg;
73 SMESHGUI_ExtrusionAlongPathDlg( QWidget* parent = 0, SALOME_Selection* Sel = 0, bool modal = FALSE );
74 ~SMESHGUI_ExtrusionAlongPathDlg();
76 bool eventFilter( QObject* object, QEvent* event );
82 void Init( bool ResetControls = true ) ;
83 void enterEvent ( QEvent * ) ; /* mouse enter the QWidget */
84 int GetConstructorId();
85 void SetEditCurrentArgument( QToolButton* button );
87 SMESHGUI* mySMESHGUI ; /* Current SMESHGUI object */
88 SALOME_Selection* mySelection ; /* User shape selection */
89 QWidget* myEditCurrentArgument; /* Current argument */
92 SMESH::SMESH_IDSource_var myIDSource;
93 SMESH::SMESH_Mesh_var myMesh;
94 SMESH_Actor* myMeshActor;
95 SMESH::SMESH_Mesh_var myPathMesh;
96 GEOM::GEOM_Object_var myPathShape;
97 Handle(SMESH_LogicalFilter) myElementsFilter;
98 Handle(SMESH_TypeFilter) myPathMeshFilter;
102 QButtonGroup* ElementsTypeGrp;
103 QRadioButton* Elements1dRB;
104 QRadioButton* Elements2dRB;
105 QGroupBox* ArgumentsGrp;
107 QToolButton* SelectElementsButton;
108 QLineEdit* ElementsLineEdit;
109 QCheckBox* MeshCheck;
112 QToolButton* SelectPathMeshButton;
113 QLineEdit* PathMeshLineEdit;
114 QLabel* PathShapeLab;
115 QToolButton* SelectPathShapeButton;
116 QLineEdit* PathShapeLineEdit;
117 QLabel* StartPointLab;
118 QToolButton* SelectStartPointButton;
119 QLineEdit* StartPointLineEdit;
120 QCheckBox* AnglesCheck;
121 QGroupBox* AnglesGrp;
122 QListBox* AnglesList;
123 QToolButton* AddAngleButton;
124 QToolButton* RemoveAngleButton;
125 SMESHGUI_SpinBox* AngleSpin;
126 QCheckBox* BasePointCheck;
127 QGroupBox* BasePointGrp;
128 QToolButton* SelectBasePointButton;
130 SMESHGUI_SpinBox* XSpin;
132 SMESHGUI_SpinBox* YSpin;
134 SMESHGUI_SpinBox* ZSpin;
135 QGroupBox* ButtonsGrp;
136 QPushButton* OkButton;
137 QPushButton* ApplyButton;
138 QPushButton* CloseButton;
141 void TypeChanged( int type );
144 void SetEditCurrentArgument();
145 void SelectionIntoArgument();
146 void DeactivateActiveDialog();
147 void ActivateThisDialog();
148 void onTextChange(const QString&);
150 void onAnglesCheck();
151 void onBasePointCheck();
153 void OnAngleRemoved();
156 #endif // DIALOGBOX_EXTRUSION_PATH_H