1 // Copyright (C) 2007-2010 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
23 // SMESH SMESHGUI : GUI for SMESH component
24 // File : SMESHGUI_AddMeshElementDlg.h
25 // Author : Nicolas REJNERI, Open CASCADE S.A.S.
27 #ifndef SMESHGUI_ADDQUADRATICELEMENTDLG_H
28 #define SMESHGUI_ADDQUADRATICELEMENTDLG_H
31 #include "SMESH_SMESHGUI.hxx"
37 #include <SALOMEconfig.h>
38 #include CORBA_SERVER_HEADER(SMESH_Mesh)
51 class LightApp_SelectionMgr;
55 struct TElementSimulation;
58 enum { QUAD_EDGE, QUAD_TRIANGLE, QUAD_QUADRANGLE, QUAD_TETRAHEDRON,
59 QUAD_PYRAMID, QUAD_PENTAHEDRON, QUAD_HEXAHEDRON };
61 //=================================================================================
62 // class : SMESHGUI_AddQuadraticElementDlg
64 //=================================================================================
65 class SMESHGUI_EXPORT SMESHGUI_AddQuadraticElementDlg : public QDialog
70 SMESHGUI_AddQuadraticElementDlg( SMESHGUI*, const int );
71 ~SMESHGUI_AddQuadraticElementDlg();
74 typedef QList<SMESH::SMESH_GroupBase_var> GrpList;
77 void closeEvent( QCloseEvent* );
78 void hideEvent( QHideEvent* ); /* ESC key */
79 void enterEvent( QEvent* ); /* mouse enter the QWidget */
80 void keyPressEvent( QKeyEvent* );
81 void displaySimulation();
82 void UpdateTable( bool = true );
88 SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
89 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
90 int myNbCorners; /* The required number of corners */
92 SVTK_Selector* mySelector;
94 SMESH::SMESH_Mesh_var myMesh;
96 SMESH::TElementSimulation* mySimulation;
101 bool myIsEditCorners;
103 QGroupBox* GroupConstructors;
104 QRadioButton* myRadioButton1;
106 QGroupBox* GroupArguments;
107 QLineEdit* myCornerNodes;
108 QPushButton* mySelectButton;
109 QTableWidget* myTable;
110 QCheckBox* myReverseCB;
112 QGroupBox* GroupGroups;
113 QLabel* TextLabel_GroupName;
114 QComboBox* ComboBox_GroupName;
116 QGroupBox* GroupButtons;
117 QPushButton* buttonOk;
118 QPushButton* buttonCancel;
119 QPushButton* buttonApply;
120 QPushButton* buttonHelp;
122 QString myHelpFileName;
125 void onTextChange( const QString& );
126 void onCellTextChange( int, int );
127 void onReverse( int );
128 void onCellDoubleClicked( int, int );
131 void ClickOnCancel();
134 void SetEditCorners();
135 void SelectionIntoArgument();
136 void DeactivateActiveDialog();
137 void ActivateThisDialog();
140 #endif // SMESHGUI_ADDQUADRATICELEMENTDLG_H