1 // Copyright (C) 2007-2008 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.
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
22 // SMESH SMESHGUI : GUI for SMESH component
23 // File : SMESHGUI_ExtrusionAlongPathDlg.h
24 // Author : Vadim SANDLER, Open CASCADE S.A.S.
26 #ifndef SMESHGUI_EXTRUSIONALONGPATHDLG_H
27 #define SMESHGUI_EXTRUSIONALONGPATHDLG_H
30 #include "SMESH_SMESHGUI.hxx"
36 #include <SALOMEconfig.h>
37 #include CORBA_SERVER_HEADER(SMESH_Mesh)
51 class SMESHGUI_IdValidator;
52 class SMESHGUI_SpinBox;
53 class SMESHGUI_FilterDlg;
55 class LightApp_SelectionMgr;
56 class SUIT_SelectionFilter;
58 //=================================================================================
59 // class : SMESHGUI_ExtrusionAlongPathDlg
61 //=================================================================================
62 class SMESHGUI_EXPORT SMESHGUI_ExtrusionAlongPathDlg : public QDialog
70 SMESHGUI_ExtrusionAlongPathDlg( SMESHGUI* );
71 ~SMESHGUI_ExtrusionAlongPathDlg();
73 bool eventFilter( QObject*, QEvent* );
76 void Init( bool = true );
77 void enterEvent( QEvent* ); /* mouse enter the QWidget */
78 void keyPressEvent( QKeyEvent* );
79 int GetConstructorId();
80 void SetEditCurrentArgument( QToolButton* );
84 void updateLinearAngles();
86 SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
87 SMESHGUI_IdValidator* myIdValidator;
88 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
89 SVTK_Selector* mySelector;
91 QWidget* myEditCurrentArgument; /* Current argument */
94 SMESH::SMESH_Mesh_var myMesh;
95 SMESH_Actor* myMeshActor;
96 SMESH::SMESH_IDSource_var myIDSource;
97 //SMESH::SMESH_Mesh_var myPathMesh;
98 SMESH::SMESH_IDSource_var myPath;
99 //GEOM::GEOM_Object_var myPathShape;
100 SUIT_SelectionFilter* myElementsFilter;
101 SUIT_SelectionFilter* myPathMeshFilter;
103 QList<double> myAnglesList;
106 QGroupBox* ConstructorsBox;
107 QButtonGroup* GroupConstructors;
108 QRadioButton* Elements1dRB;
109 QRadioButton* Elements2dRB;
111 QGroupBox* GroupArguments;
113 QToolButton* SelectElementsButton;
114 QLineEdit* ElementsLineEdit;
115 QCheckBox* MeshCheck;
117 QToolButton* SelectPathMeshButton;
118 QLineEdit* PathMeshLineEdit;
119 //QToolButton* SelectPathShapeButton;
120 //QLineEdit* PathShapeLineEdit;
121 QToolButton* SelectStartPointButton;
122 QLineEdit* StartPointLineEdit;
123 QCheckBox* LinearAnglesCheck;
124 QGroupBox* AnglesGrp;
125 QListWidget* AnglesList;
126 QToolButton* AddAngleButton;
127 QToolButton* RemoveAngleButton;
128 SMESHGUI_SpinBox* AngleSpin;
129 QGroupBox* BasePointGrp;
130 QToolButton* SelectBasePointButton;
131 SMESHGUI_SpinBox* XSpin;
132 SMESHGUI_SpinBox* YSpin;
133 SMESHGUI_SpinBox* ZSpin;
134 QCheckBox* MakeGroupsCheck;
136 QGroupBox* GroupButtons;
137 QPushButton* OkButton;
138 QPushButton* ApplyButton;
139 QPushButton* CloseButton;
140 QPushButton* HelpButton;
142 QString myHelpFileName;
144 QPushButton* myFilterBtn;
145 SMESHGUI_FilterDlg* myFilterDlg;
151 void ConstructorsClicked( int );
155 void SetEditCurrentArgument();
156 void SelectionIntoArgument();
157 void DeactivateActiveDialog();
158 void ActivateThisDialog();
159 void onTextChange( const QString& );
162 void OnAngleRemoved();
166 #endif // SMESHGUI_EXTRUSIONALONGPATHDLG_H