1 // Copyright (C) 2007-2010 CEA/DEN, EDF R&D, OPEN CASCADE
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 // SMESH SMESHGUI : GUI for SMESH component
21 // File : SMESHGUI_ScaleDlg.h
22 // Author : Sergey Kuul, Open CASCADE S.A.S.
24 #ifndef SMESHGUI_SCALEDLG_H
25 #define SMESHGUI_SCALEDLG_H
28 #include "SMESH_SMESHGUI.hxx"
34 #include <SALOMEconfig.h>
35 #include CORBA_SERVER_HEADER(SMESH_Mesh)
45 class SMESHGUI_IdValidator;
46 class SMESHGUI_SpinBox;
47 class SMESHGUI_FilterDlg;
50 class LightApp_SelectionMgr;
51 class SMESH_LogicalFilter;
53 //=================================================================================
54 // class : SMESHGUI_ScaleDlg
56 //=================================================================================
57 class SMESHGUI_EXPORT SMESHGUI_ScaleDlg : public QDialog
62 SMESHGUI_ScaleDlg( SMESHGUI* );
66 void Init( bool = true );
67 void closeEvent( QCloseEvent* );
68 void enterEvent( QEvent* ); /* mouse enter the QWidget */
69 void hideEvent( QHideEvent* ); /* ESC key */
70 void keyPressEvent( QKeyEvent* );
71 int GetConstructorId();
72 void setNewMeshName();
76 SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */
77 SMESHGUI_IdValidator* myIdValidator;
78 LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */
80 int myNbOkElements; /* to check when elements are defined */
82 SVTK_Selector* mySelector;
84 QWidget* myEditCurrentArgument;
87 SMESH::SMESH_Mesh_var myMesh;
89 SMESH_LogicalFilter* myMeshOrSubMeshOrGroupFilter;
91 SMESH::SMESH_IDSource_var mySelectedObject;
93 QGroupBox* ConstructorsBox;
94 QButtonGroup* GroupConstructors;
95 QRadioButton* RadioButton1;
96 QRadioButton* RadioButton2;
97 QGroupBox* GroupButtons;
98 QPushButton* buttonOk;
99 QPushButton* buttonCancel;
100 QPushButton* buttonApply;
101 QPushButton* buttonHelp;
102 QGroupBox* GroupArguments;
103 QLabel* TextLabelElements;
104 QPushButton* SelectElementsButton;
105 QLineEdit* LineEditElements;
106 QCheckBox* CheckBoxMesh;
108 QPushButton* SelectButton1;
109 QLabel* TextLabel1_1;
110 SMESHGUI_SpinBox* SpinBox1_1;
111 QLabel* TextLabel1_2;
112 SMESHGUI_SpinBox* SpinBox1_2;
113 QLabel* TextLabel1_3;
114 SMESHGUI_SpinBox* SpinBox1_3;
116 SMESHGUI_SpinBox* SpinBox_FX;
118 SMESHGUI_SpinBox* SpinBox_FY;
120 SMESHGUI_SpinBox* SpinBox_FZ;
121 QGroupBox* ActionBox;
122 QButtonGroup* ActionGroup;
123 QCheckBox* MakeGroupsCheck;
124 QLineEdit* LineEditNewMesh;
126 QString myHelpFileName;
128 QPushButton* myFilterBtn;
129 SMESHGUI_FilterDlg* myFilterDlg;
132 void ConstructorsClicked( int );
134 void ClickOnCancel();
137 void SetEditCurrentArgument();
138 void SelectionIntoArgument();
139 void DeactivateActiveDialog();
140 void ActivateThisDialog();
141 void onTextChange( const QString& );
142 void onSelectMesh( bool );
143 void onActionClicked( int );
147 #endif // SMESHGUI_SCALEDLG_H