X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_SewingDlg.h;h=2bf5c591c128767ee73cfb2b3e35d61bd3dd841f;hb=18dade91d06a5b9964bb5604dbfdbc0ff4deef0a;hp=d21d1b5738c9d58fe5f9c5f0cc06c7918194af65;hpb=0635c9fc80f67d1e5dc0e94ec85f487286a92070;p=modules%2Fsmesh.git diff --git a/src/SMESHGUI/SMESHGUI_SewingDlg.h b/src/SMESHGUI/SMESHGUI_SewingDlg.h index d21d1b573..2bf5c591c 100644 --- a/src/SMESHGUI/SMESHGUI_SewingDlg.h +++ b/src/SMESHGUI/SMESHGUI_SewingDlg.h @@ -1,24 +1,25 @@ -// Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE // -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS // -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. // -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. // -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // + // SMESH SMESHGUI : GUI for SMESH component // File : SMESHGUI_SewingDlg.h // Author : Michael ZORIN, Open CASCADE S.A.S. @@ -35,6 +36,9 @@ // IDL includes #include #include CORBA_SERVER_HEADER(SMESH_Mesh) +#include CORBA_SERVER_HEADER(SMESH_MeshEditor) + +#include class QButtonGroup; class QGroupBox; @@ -47,6 +51,10 @@ class SMESHGUI; class SMESH_Actor; class SVTK_Selector; class LightApp_SelectionMgr; +class SMESHGUI_SpinBox; +class SalomeApp_IntSpinBox; +class QListWidget; +class QListWidgetItem; //================================================================================= // class : SMESHGUI_SewingDlg @@ -62,13 +70,12 @@ public: private: void Init(); - void closeEvent( QCloseEvent* ); void enterEvent( QEvent* ); /* mouse enter the QWidget */ - void hideEvent( QHideEvent* ); /* ESC key */ void keyPressEvent( QKeyEvent* ); int GetConstructorId(); bool IsValid(); - + void UpdateButtons(); + SMESHGUI* mySMESHGUI; /* Current SMESHGUI object */ LightApp_SelectionMgr* mySelectionMgr; /* User shape selection */ int myOk1, myOk2, myOk3, myOk4, myOk5, myOk6; @@ -115,12 +122,68 @@ private: QCheckBox* CheckBoxPolygons; QCheckBox* CheckBoxPolyedrs; + QWidget* SewFreeBordersWidget; + QGroupBox* ModeGroup; + QButtonGroup* ModeButGrp; + //QPushButton* SelectMeshButton; + QLineEdit* LineEditMesh; + + SMESHGUI_SpinBox* SpinBoxTolerance; + QCheckBox* AutoSewCheck; + + QWidget* GroupCoincidentWidget; + QListWidget* ListCoincident; + QPushButton* DetectButton; + QPushButton* RemoveGroupButton; + QCheckBox* SelectAllCheck; + + QListWidget* ListEdit; + QButtonGroup* MoveBorderEndsButGrp; + QLineEdit* BorderEndLine[2]; + QPushButton* SwapBut; + QPushButton* SetFirstButton; + QPushButton* RemoveElemButton; + SalomeApp_IntSpinBox* StepSpin; + QString myHelpFileName; -private slots: + + struct BorderGroupDisplayer; + std::vector< BorderGroupDisplayer* > myBorderDisplayers; + SMESH::CoincidentFreeBorders_var myBorders; + int myCurGroupIndex; + int myCurPartIndex; + int myStoredRepresentation; + unsigned int myStoredEntityMode; + + bool haveBorders(); + QString getGroupText( int groupIndex ); + QString getPartText( const SMESH::FreeBorderPart& part ); + void showGroup( QListWidgetItem* item ); + bool setCurrentGroup(); + bool setCurrentPart(); + void onGroupChange(bool partChange=false); + void setDisplayMode(); + void restoreDisplayMode(); + + + protected slots: + virtual void reject(); + + private slots: void ConstructorsClicked( int ); + void onModeChange( int ); + void onAutoSew( int ); + void onDetectClicked(); + void onRemoveGroupClicked(); + void onSelectGroup(); + void onSelectAll(int); + void onSelectBorderPartFromGroup(); + void onSetFirstClicked(); + void onRemoveElemClicked(); + void onMoveBorderEnd(int); + void onSwapClicked(); void ClickOnOk(); - void ClickOnCancel(); bool ClickOnApply(); void ClickOnHelp(); void SetEditCurrentArgument(); @@ -128,6 +191,8 @@ private slots: void DeactivateActiveDialog(); void ActivateThisDialog(); void onTextChange( const QString& ); + void onOpenView(); + void onCloseView(); }; #endif // SMESHGUI_SEWINGDLG_H