Version: 8.3.0
SMESHGUI_CreatePolyhedralVolumeDlg.h
Go to the documentation of this file.
1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
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, or (at your option) any later version.
10 //
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.
15 //
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
19 //
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22 
23 // SMESH SMESHGUI : GUI for SMESH component
24 // File : SMESHGUI_CreatePolyhedralVolumeDlg.h
25 // Author : Michael ZORIN, Open CASCADE S.A.S.
26 //
27 #ifndef SMESHGUI_CREATEPOLYHEDRALVOLUMEDLG_H
28 #define SMESHGUI_CREATEPOLYHEDRALVOLUMEDLG_H
29 
30 // SMESH includes
31 #include "SMESH_SMESHGUI.hxx"
32 
33 // Qt includes
34 #include <QDialog>
35 
36 // IDL includes
37 #include <SALOMEconfig.h>
38 #include CORBA_SERVER_HEADER(SMESH_Mesh)
39 
40 class QButtonGroup;
41 class QComboBox;
42 class QGroupBox;
43 class QListWidget;
44 class QLabel;
45 class QLineEdit;
46 class QPushButton;
47 class QRadioButton;
48 class QCheckBox;
49 class SMESHGUI;
50 class SMESH_Actor;
51 class SVTK_Selector;
52 class LightApp_SelectionMgr;
53 
54 namespace SMESH
55 {
56  struct TPolySimulation;
57 }
58 
59 //=================================================================================
60 // class : SMESHGUI_CreatePolyhedralVolumeDlg
61 // purpose :
62 //=================================================================================
64 {
65  Q_OBJECT
66 
67 public:
70 
71 private:
72  typedef QList<SMESH::SMESH_GroupBase_var> GrpList;
73 
74  void Init();
75  void enterEvent( QEvent* ); /* mouse enter the QWidget */
76  void keyPressEvent( QKeyEvent* );
77  int GetConstructorId();
78  void displaySimulation();
79 
80  bool isValid();
81 
82  int checkEditLine( bool = true );
84  SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
85  LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
86  SVTK_Selector* mySelector;
87  QString myIDs;
88  int myNbOkElements; /* to check when elements are defined */
89 
91 
92  SMESH::SMESH_Mesh_var myMesh;
95  QString myEntry;
97 
99  QButtonGroup* GroupConstructors;
100  QRadioButton* RadioButton1;
101  QRadioButton* RadioButton2;
102  QCheckBox* Preview;
105  QComboBox* ComboBox_GroupName;
107  QPushButton* buttonOk;
108  QPushButton* buttonCancel;
109  QPushButton* buttonApply;
110  QPushButton* buttonHelp;
112  QLabel* TextLabelIds;
113  QPushButton* SelectElementsButton;
114  QLineEdit* LineEditElements;
115  QListWidget* myFacesByNodes;
117  QPushButton* AddButton;
118  QPushButton* RemoveButton;
119 
120  QString myHelpFileName;
121 
122 public slots:
123  void onAdd();
124  void onRemove();
125 
126 protected slots:
127  virtual void reject();
128 
129 private slots:
130  void ConstructorsClicked( int );
131  void ClickOnPreview( bool );
132  void ClickOnOk();
133  void ClickOnApply();
134  void ClickOnHelp();
135  void SetEditCurrentArgument();
136  void SelectionIntoArgument();
137  void DeactivateActiveDialog();
138  void ActivateThisDialog();
139  void onTextChange( const QString& );
140  void onListSelectionChanged();
141  void onOpenView();
142  void onCloseView();
143 };
144 
145 #endif // SMESHGUI_CREATEPOLYHEDRALVOLUMEDLG_H