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_AddMeshElementDlg.h
24 // Author : Nicolas REJNERI, Open CASCADE S.A.S.
26 #ifndef SMESHGUI_ADDQUADRATICELEMENTDLG_H
27 #define SMESHGUI_ADDQUADRATICELEMENTDLG_H
30 #include "SMESH_SMESHGUI.hxx"
36 #include <SALOMEconfig.h>
37 #include CORBA_SERVER_HEADER(SMESH_Mesh)
50 class LightApp_SelectionMgr;
54 struct TElementSimulation;
57 enum { QUAD_EDGE, QUAD_TRIANGLE, QUAD_QUADRANGLE, QUAD_TETRAHEDRON,
58 QUAD_PYRAMID, QUAD_PENTAHEDRON, QUAD_HEXAHEDRON };
60 //=================================================================================
61 // class : SMESHGUI_AddQuadraticElementDlg
63 //=================================================================================
64 class SMESHGUI_EXPORT SMESHGUI_AddQuadraticElementDlg : public QDialog
69 SMESHGUI_AddQuadraticElementDlg( SMESHGUI*, const int );
70 ~SMESHGUI_AddQuadraticElementDlg();
74 void closeEvent( QCloseEvent* );
75 void hideEvent( QHideEvent* ); /* ESC key */
76 void enterEvent( QEvent* ); /* mouse enter the QWidget */
77 void keyPressEvent( QKeyEvent* );
78 void displaySimulation();
79 void UpdateTable( bool = true );
85 SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
86 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
87 int myNbCorners; /* The required number of corners */
89 SVTK_Selector* mySelector;
91 SMESH::SMESH_Mesh_var myMesh;
93 SMESH::TElementSimulation* mySimulation;
99 QGroupBox* GroupConstructors;
100 QRadioButton* myRadioButton1;
102 QGroupBox* GroupArguments;
103 QLineEdit* myCornerNodes;
104 QPushButton* mySelectButton;
105 QTableWidget* myTable;
106 QCheckBox* myReverseCB;
108 QGroupBox* GroupGroups;
109 QLabel* TextLabel_GroupName;
110 QComboBox* ComboBox_GroupName;
112 QGroupBox* GroupButtons;
113 QPushButton* buttonOk;
114 QPushButton* buttonCancel;
115 QPushButton* buttonApply;
116 QPushButton* buttonHelp;
118 QString myHelpFileName;
121 void onTextChange( const QString& );
122 void onCellTextChange( int, int );
123 void onReverse( int );
124 void onCellDoubleClicked( int, int );
127 void ClickOnCancel();
130 void SetEditCorners();
131 void SelectionIntoArgument();
132 void DeactivateActiveDialog();
133 void ActivateThisDialog();
136 #endif // SMESHGUI_ADDQUADRATICELEMENTDLG_H