1 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License.
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 // File : SMESHGUI_ComputeDlg.h
21 // Author : Edward AGAPOV, Open CASCADE S.A.S.
24 #ifndef SMESHGUI_COMPUTEDLG_H
25 #define SMESHGUI_COMPUTEDLG_H
28 #include "SMESH_SMESHGUI.hxx"
30 #include "SMESHGUI_Dialog.h"
31 #include "SMESHGUI_Operation.h"
37 #include <SALOMEconfig.h>
38 #include CORBA_SERVER_HEADER(SMESH_Mesh)
44 class SMESHGUI_ComputeDlg;
45 class SMESHGUI_MeshEditPreview;
49 class TShapeDisplayer;
53 * \brief Operation to compute a mesh and show computation errors
55 class SMESHGUI_EXPORT SMESHGUI_ComputeOp: public SMESHGUI_Operation
61 virtual ~SMESHGUI_ComputeOp();
63 virtual LightApp_Dialog* dlg() const;
66 virtual void startOperation();
67 virtual void stopOperation();
70 virtual bool onApply();
73 void onPreviewShape();
74 void onPublishShape();
76 void currentCellChanged();
79 QTableWidget* table();
81 SMESHGUI_ComputeDlg* myDlg;
83 SMESH::SMESH_Mesh_var myMesh;
84 GEOM::GEOM_Object_var myMainShape;
85 SMESH::TShapeDisplayer* myTShapeDisplayer;
86 SMESHGUI_MeshEditPreview* myBadMeshDisplayer;
90 * \brief Box showing mesh info
93 class SMESHGUI_EXPORT SMESHGUI_MeshInfosBox : public QGroupBox
98 SMESHGUI_MeshInfosBox( const bool, QWidget* );
100 void SetInfoByMesh( SMESH::SMESH_Mesh_var );
107 QLabel* myNbQuadEdge;
110 QLabel* myNbQuadTrai;
113 QLabel* myNbQuadQuad;
116 QLabel* myNbQuadFace;
120 QLabel* myNbQuadHexa;
122 QLabel* myNbLinTetra;
123 QLabel* myNbQuadTetra;
126 QLabel* myNbQuadPyra;
128 QLabel* myNbLinPrism;
129 QLabel* myNbQuadPrism;
131 QLabel* myNbLinVolum;
132 QLabel* myNbQuadVolum;
137 * \brief Dialog to compute a mesh and show computation errors
140 class SMESHGUI_EXPORT SMESHGUI_ComputeDlg : public SMESHGUI_Dialog
145 SMESHGUI_ComputeDlg();
148 QFrame* createMainFrame( QWidget* );
151 QGroupBox* myMemoryLackGroup;
152 QGroupBox* myCompErrorGroup;
153 QGroupBox* myHypErrorGroup;
154 QLabel* myHypErrorLabel;
155 QTableWidget* myTable;
156 QPushButton* myShowBtn;
157 QPushButton* myPublishBtn;
158 QPushButton* myBadMeshBtn;
160 SMESHGUI_MeshInfosBox* myBriefInfo;
161 SMESHGUI_MeshInfosBox* myFullInfo;
163 friend class SMESHGUI_ComputeOp;
166 #endif // SMESHGUI_COMPUTEDLG_H