From c2e8e86f2f34664f2dc1d7f64fae1f35ceca532c Mon Sep 17 00:00:00 2001 From: vsr Date: Wed, 17 Oct 2007 06:10:49 +0000 Subject: [PATCH] *** empty log message *** --- src/EntityGUI/EntityGUI.cxx | 165 +- src/EntityGUI/EntityGUI.h | 57 +- src/EntityGUI/EntityGUI_1Sel_QTD.h | 172 -- src/EntityGUI/EntityGUI_1Sel_QTD.ui | 126 ++ src/EntityGUI/EntityGUI_1Spin.cxx | 59 - src/EntityGUI/EntityGUI_1Spin.h | 50 - src/EntityGUI/EntityGUI_1Spin_QTD.h | 160 -- src/EntityGUI/EntityGUI_1Spin_QTD.ui | 101 ++ src/EntityGUI/EntityGUI_2Spin.cxx | 64 - src/EntityGUI/EntityGUI_2Spin.h | 51 - src/EntityGUI/EntityGUI_2Spin_QTD.h | 184 --- src/EntityGUI/EntityGUI_2Spin_QTD.ui | 123 ++ src/EntityGUI/EntityGUI_3Spin.cxx | 68 - src/EntityGUI/EntityGUI_3Spin.h | 52 - src/EntityGUI/EntityGUI_3Spin_QTD.h | 208 --- src/EntityGUI/EntityGUI_3Spin_QTD.ui | 145 ++ src/EntityGUI/EntityGUI_4Spin.cxx | 73 - src/EntityGUI/EntityGUI_4Spin.h | 53 - src/EntityGUI/EntityGUI_4Spin_QTD.h | 232 --- src/EntityGUI/EntityGUI_4Spin_QTD.ui | 167 ++ src/EntityGUI/EntityGUI_Dir1_QTD.h | 114 -- src/EntityGUI/EntityGUI_Dir1_QTD.ui | 85 + src/EntityGUI/EntityGUI_Dir2_QTD.h | 112 -- src/EntityGUI/EntityGUI_Dir2_QTD.ui | 77 + src/EntityGUI/EntityGUI_Point_QTD.h | 106 -- src/EntityGUI/EntityGUI_Point_QTD.ui | 77 + src/EntityGUI/EntityGUI_Skeleton_QTD.h | 287 ---- src/EntityGUI/EntityGUI_Skeleton_QTD.ui | 206 +++ src/EntityGUI/EntityGUI_SketcherDlg.cxx | 1400 ++++++++--------- src/EntityGUI/EntityGUI_SketcherDlg.h | 251 +-- src/EntityGUI/EntityGUI_SubShapeDlg.cxx | 295 ++-- src/EntityGUI/EntityGUI_SubShapeDlg.h | 117 +- src/EntityGUI/EntityGUI_Widgets.cxx | 172 ++ src/EntityGUI/EntityGUI_Widgets.h | 181 +++ src/EntityGUI/GEOM_EntityGUI.hxx | 47 - src/EntityGUI/Makefile.am | 128 +- src/EntityGUI/UIFiles/EntityGUI_1Sel_QTD.ui | 182 --- src/EntityGUI/UIFiles/EntityGUI_1Spin_QTD.ui | 167 -- src/EntityGUI/UIFiles/EntityGUI_2Spin_QTD.ui | 197 --- src/EntityGUI/UIFiles/EntityGUI_3Spin_QTD.ui | 227 --- src/EntityGUI/UIFiles/EntityGUI_4Spin_QTD.ui | 257 --- src/EntityGUI/UIFiles/EntityGUI_Dir1_QTD.ui | 96 -- src/EntityGUI/UIFiles/EntityGUI_Dir2_QTD.ui | 104 -- src/EntityGUI/UIFiles/EntityGUI_Point_QTD.ui | 88 -- .../UIFiles/EntityGUI_Skeleton_QTD.ui | 321 ---- src/EntityGUI/UIFiles/ui_to_cxx | 37 - 46 files changed, 2590 insertions(+), 5051 deletions(-) delete mode 100644 src/EntityGUI/EntityGUI_1Sel_QTD.h create mode 100644 src/EntityGUI/EntityGUI_1Sel_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_1Spin.cxx delete mode 100644 src/EntityGUI/EntityGUI_1Spin.h delete mode 100644 src/EntityGUI/EntityGUI_1Spin_QTD.h create mode 100644 src/EntityGUI/EntityGUI_1Spin_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_2Spin.cxx delete mode 100644 src/EntityGUI/EntityGUI_2Spin.h delete mode 100644 src/EntityGUI/EntityGUI_2Spin_QTD.h create mode 100644 src/EntityGUI/EntityGUI_2Spin_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_3Spin.cxx delete mode 100644 src/EntityGUI/EntityGUI_3Spin.h delete mode 100644 src/EntityGUI/EntityGUI_3Spin_QTD.h create mode 100644 src/EntityGUI/EntityGUI_3Spin_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_4Spin.cxx delete mode 100644 src/EntityGUI/EntityGUI_4Spin.h delete mode 100644 src/EntityGUI/EntityGUI_4Spin_QTD.h create mode 100644 src/EntityGUI/EntityGUI_4Spin_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_Dir1_QTD.h create mode 100644 src/EntityGUI/EntityGUI_Dir1_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_Dir2_QTD.h create mode 100644 src/EntityGUI/EntityGUI_Dir2_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_Point_QTD.h create mode 100644 src/EntityGUI/EntityGUI_Point_QTD.ui delete mode 100644 src/EntityGUI/EntityGUI_Skeleton_QTD.h create mode 100644 src/EntityGUI/EntityGUI_Skeleton_QTD.ui create mode 100644 src/EntityGUI/EntityGUI_Widgets.cxx create mode 100644 src/EntityGUI/EntityGUI_Widgets.h delete mode 100755 src/EntityGUI/GEOM_EntityGUI.hxx delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_1Sel_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_1Spin_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_2Spin_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_3Spin_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_4Spin_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_Dir1_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_Dir2_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_Point_QTD.ui delete mode 100644 src/EntityGUI/UIFiles/EntityGUI_Skeleton_QTD.ui delete mode 100755 src/EntityGUI/UIFiles/ui_to_cxx diff --git a/src/EntityGUI/EntityGUI.cxx b/src/EntityGUI/EntityGUI.cxx index 35387d0a6..2bdb051f4 100644 --- a/src/EntityGUI/EntityGUI.cxx +++ b/src/EntityGUI/EntityGUI.cxx @@ -1,59 +1,52 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI.cxx +// Author : Damien COQUERET, Open CASCADE S.A.S. // -// -// File : EntityGUI.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header$ #include "EntityGUI.h" -#include "GeometryGUI.h" -#include "SUIT_Desktop.h" -#include "SUIT_ViewWindow.h" -#include "OCCViewer_ViewModel.h" -#include "OCCViewer_ViewManager.h" -#include "SalomeApp_Study.h" -#include "SalomeApp_Application.h" +#include + +#include +#include +#include +#include +#include +#include #include #include "EntityGUI_SketcherDlg.h" // Sketcher #include "EntityGUI_SubShapeDlg.h" // Method SUBSHAPE -#include "utilities.h" - -using namespace boost; -using namespace std; - //======================================================================= // function : EntityGUI() // purpose : Constructor //======================================================================= EntityGUI::EntityGUI( GeometryGUI* parent ) : GEOMGUI( parent ) { - mySimulationShape1 = new AIS_Shape(TopoDS_Shape()); - mySimulationShape2 = new AIS_Shape(TopoDS_Shape()); + mySimulationShape1 = new AIS_Shape( TopoDS_Shape() ); + mySimulationShape2 = new AIS_Shape( TopoDS_Shape() ); } //======================================================================= @@ -69,7 +62,7 @@ EntityGUI::~EntityGUI() // function : OnGUIEvent() // purpose : //======================================================================= -bool EntityGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent) +bool EntityGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent ) { SalomeApp_Application* app = getGeometryGUI()->getApp(); if ( !app ) return false; @@ -77,22 +70,21 @@ bool EntityGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent) getGeometryGUI()->EmitSignalDeactivateDialog(); QDialog* aDlg = NULL; - switch (theCommandID) - { - case 404: // SKETCHER - getGeometryGUI()->ActiveWorkingPlane(); - aDlg = new EntityGUI_SketcherDlg(getGeometryGUI(), parent, ""); - break; - case 407: // EXPLODE : use ic - aDlg = new EntityGUI_SubShapeDlg(getGeometryGUI(), parent, ""); - break; - default: - app->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID)); - break; + switch ( theCommandID ) { + case 404: // SKETCHER + getGeometryGUI()->ActiveWorkingPlane(); + aDlg = new EntityGUI_SketcherDlg( getGeometryGUI(), parent ); + break; + case 407: // EXPLODE : use ic + aDlg = new EntityGUI_SubShapeDlg( getGeometryGUI(), parent ); + break; + default: + app->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) ); + break; } if ( aDlg ) aDlg->show(); - + return true; } @@ -101,49 +93,48 @@ bool EntityGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent) // function : DisplaySimulationShape() // purpose : Displays 'this->mySimulationShape' a pure graphical shape from a TopoDS_Shape //===================================================================================== -void EntityGUI::DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2) +void EntityGUI::DisplaySimulationShape( const TopoDS_Shape& S1, const TopoDS_Shape& S2 ) { SalomeApp_Application* app = getGeometryGUI()->getApp(); if ( !app ) return; SUIT_ViewManager* aVM = app->desktop()->activeWindow()->getViewManager(); - if (aVM->getType() != OCCViewer_Viewer::Type()) + if ( aVM->getType() != OCCViewer_Viewer::Type() ) return; - OCCViewer_Viewer* v3d = ((OCCViewer_ViewManager*)aVM)->getOCCViewer(); + OCCViewer_Viewer* v3d = ( (OCCViewer_ViewManager*)aVM )->getOCCViewer(); Handle(AIS_InteractiveContext) ic = v3d->getAISContext(); try { - if (!S1.IsNull()) { + if ( !S1.IsNull() ) { /* erase any previous */ - ic->Erase(mySimulationShape1, Standard_True, Standard_False); - ic->ClearPrs(mySimulationShape1); + ic->Erase( mySimulationShape1, Standard_True, Standard_False ); + ic->ClearPrs( mySimulationShape1 ); - mySimulationShape1 = new AIS_Shape(TopoDS_Shape()); - mySimulationShape1->Set(S1); - mySimulationShape1->SetColor(Quantity_NOC_RED); + mySimulationShape1 = new AIS_Shape( TopoDS_Shape() ); + mySimulationShape1->Set( S1 ); + mySimulationShape1->SetColor( Quantity_NOC_RED ); - ic->Deactivate(mySimulationShape1); - ic->Display(mySimulationShape1, Standard_False); + ic->Deactivate( mySimulationShape1 ); + ic->Display( mySimulationShape1, Standard_False ); mySimulationShape1->UnsetColor(); } - if (!S2.IsNull()) { - ic->Erase(mySimulationShape2, Standard_True, Standard_False); - ic->ClearPrs(mySimulationShape2); + if ( !S2.IsNull() ) { + ic->Erase( mySimulationShape2, Standard_True, Standard_False ); + ic->ClearPrs( mySimulationShape2 ); - mySimulationShape2 = new AIS_Shape(TopoDS_Shape()); - mySimulationShape2->Set(S2); - mySimulationShape2->SetColor(Quantity_NOC_VIOLET); + mySimulationShape2 = new AIS_Shape( TopoDS_Shape() ); + mySimulationShape2->Set( S2 ); + mySimulationShape2->SetColor( Quantity_NOC_VIOLET ); - ic->Deactivate(mySimulationShape2); - ic->Display(mySimulationShape2, Standard_False); + ic->Deactivate( mySimulationShape2 ); + ic->Display( mySimulationShape2, Standard_False ); mySimulationShape2->UnsetColor(); } ic->UpdateCurrentViewer(); } - catch(Standard_Failure) { - MESSAGE("Exception catched in EntityGUI::DisplaySimulationShape "); + catch( Standard_Failure ) { + MESSAGE( "Exception catched in EntityGUI::DisplaySimulationShape" ); } - return; } //================================================================================== @@ -162,19 +153,19 @@ void EntityGUI::EraseSimulationShape() SUIT_ViewWindow* vw; QListIterator itWL( aWndLst ); - while ( itWL.hasNext() && (vw = itWL.next()) ) + while ( itWL.hasNext() && ( vw = itWL.next() ) ) if ( vw->getViewManager()->study() == app->activeStudy() ) aWndLstAS.append( vw ); QListIterator itWLAS( aWndLstAS ); - while ( itWLAS.hasNext() && (vw = itWLAS.next()) ) { + while ( itWLAS.hasNext() && ( vw = itWLAS.next() ) ) { if ( vw->getViewManager()->getType() == OCCViewer_Viewer::Type() ) { - OCCViewer_Viewer* v3d = ((OCCViewer_ViewManager*)(vw->getViewManager()))->getOCCViewer(); + OCCViewer_Viewer* v3d = ( (OCCViewer_ViewManager*)( vw->getViewManager() ) )->getOCCViewer(); Handle(AIS_InteractiveContext) ic = v3d->getAISContext(); - ic->Erase(mySimulationShape1, Standard_True, Standard_False); - ic->ClearPrs(mySimulationShape1); - ic->Erase(mySimulationShape2, Standard_True, Standard_False); - ic->ClearPrs(mySimulationShape2); + ic->Erase( mySimulationShape1, Standard_True, Standard_False ); + ic->ClearPrs( mySimulationShape1 ); + ic->Erase( mySimulationShape2, Standard_True, Standard_False ); + ic->ClearPrs( mySimulationShape2 ); ic->UpdateCurrentViewer(); } } @@ -184,7 +175,7 @@ void EntityGUI::EraseSimulationShape() // function : SObjectExist() // purpose : //===================================================================================== -bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR) +bool EntityGUI::SObjectExist( const _PTR(SObject)& theFatherObject, const char* IOR ) { SalomeApp_Application* app = getGeometryGUI()->getApp(); if ( !app ) return false; @@ -192,20 +183,20 @@ bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* I if ( !appStudy ) return false; _PTR(Study) aStudy = appStudy->studyDS(); - _PTR(ChildIterator) it ( aStudy->NewChildIterator(theFatherObject) ); + _PTR(ChildIterator) it ( aStudy->NewChildIterator( theFatherObject ) ); _PTR(SObject) RefSO; _PTR(GenericAttribute) anAttr; - for(; it->More();it->Next()) { + for ( ; it->More();it->Next() ) { _PTR(SObject) SO ( it->Value() ); - if(SO->FindAttribute(anAttr, "AttributeIOR")) { + if ( SO->FindAttribute( anAttr, "AttributeIOR" ) ) { _PTR(AttributeIOR) anIOR ( anAttr ); - if(strcmp( anIOR->Value().c_str(), IOR ) == 0) + if ( strcmp( anIOR->Value().c_str(), IOR ) == 0 ) return true; } - if(SO->ReferencedObject(RefSO)) { - if(RefSO->FindAttribute(anAttr, "AttributeIOR")) { + if ( SO->ReferencedObject( RefSO ) ) { + if ( RefSO->FindAttribute( anAttr, "AttributeIOR" ) ) { _PTR(AttributeIOR) anIOR ( anAttr ); - if(strcmp(anIOR->Value().c_str(), IOR) == 0) + if ( strcmp( anIOR->Value().c_str(), IOR ) == 0 ) return true; } } @@ -219,7 +210,9 @@ bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* I //===================================================================================== extern "C" { -GEOM_ENTITYGUI_EXPORT +#ifdef WIN32 + __declspec( dllexport ) +#endif GEOMGUI* GetLibGUI( GeometryGUI* parent ) { return new EntityGUI( parent ); diff --git a/src/EntityGUI/EntityGUI.h b/src/EntityGUI/EntityGUI.h index 0b7356173..43e754f83 100644 --- a/src/EntityGUI/EntityGUI.h +++ b/src/EntityGUI/EntityGUI.h @@ -1,38 +1,34 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI.h +// Author : Damien COQUERET, Open CASCADE S.A.S. // -// -// File : EntityGUI.h -// Author : Damien COQUERET -// Module : GEOM #ifndef ENTITYGUI_H #define ENTITYGUI_H -#include "GEOM_EntityGUI.hxx" - -#include "GEOMGUI.h" +#include -#include "SALOMEDSClient.hxx" +#include #include @@ -42,23 +38,24 @@ class TopoDS_Shape; // class : EntityGUI // purpose : //================================================================================= -class GEOM_ENTITYGUI_EXPORT EntityGUI : public GEOMGUI +class EntityGUI : public GEOMGUI { public : - EntityGUI( GeometryGUI* parent ); // hide constructor to avoid direct creation + EntityGUI( GeometryGUI* ); ~EntityGUI(); - bool OnGUIEvent(int theCommandID, SUIT_Desktop* parent); + bool OnGUIEvent( int, SUIT_Desktop* ); - void DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2); - void EraseSimulationShape(); + void DisplaySimulationShape( const TopoDS_Shape&, const TopoDS_Shape& ); + void EraseSimulationShape(); // Methods for sub shapes explode - bool SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR); + bool SObjectExist( const _PTR(SObject)&, const char* ); +public: // AIS shape used only during topo/geom simulations Handle(AIS_Shape) mySimulationShape1; Handle(AIS_Shape) mySimulationShape2; }; -#endif +#endif // ENTITYGUI_H diff --git a/src/EntityGUI/EntityGUI_1Sel_QTD.h b/src/EntityGUI/EntityGUI_1Sel_QTD.h deleted file mode 100644 index aeb0a3fa1..000000000 --- a/src/EntityGUI/EntityGUI_1Sel_QTD.h +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_1Sel_QTD.ui' -** -** Created: Tue Jul 10 10:38:07 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_1SEL_QTD_H -#define ENTITYGUI_1SEL_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_1Sel_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupBox1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QGridLayout *gridLayout3; - QSpacerItem *spacerItem; - QPushButton *buttonApply; - QGridLayout *gridLayout4; - QPushButton *buttonRedo; - QPushButton *buttonUndo; - QGridLayout *gridLayout5; - QLabel *TextLabel1; - QSpacerItem *spacerItem1; - QPushButton *PushButton1; - QLineEdit *LineEdit1; - - void setupUi(QWidget *EntityGUI_1Sel_QTD) - { - EntityGUI_1Sel_QTD->setObjectName(QString::fromUtf8("EntityGUI_1Sel_QTD")); - gridLayout = new QGridLayout(EntityGUI_1Sel_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupBox1 = new QGroupBox(EntityGUI_1Sel_QTD); - GroupBox1->setObjectName(QString::fromUtf8("GroupBox1")); - gridLayout1 = new QGridLayout(GroupBox1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - gridLayout3 = new QGridLayout(); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(0); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - spacerItem = new QSpacerItem(0, 163, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout3->addItem(spacerItem, 2, 0, 1, 1); - - buttonApply = new QPushButton(GroupBox1); - buttonApply->setObjectName(QString::fromUtf8("buttonApply")); - - gridLayout3->addWidget(buttonApply, 0, 0, 1, 1); - - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - buttonRedo = new QPushButton(GroupBox1); - buttonRedo->setObjectName(QString::fromUtf8("buttonRedo")); - - gridLayout4->addWidget(buttonRedo, 0, 1, 1, 1); - - buttonUndo = new QPushButton(GroupBox1); - buttonUndo->setObjectName(QString::fromUtf8("buttonUndo")); - - gridLayout4->addWidget(buttonUndo, 0, 0, 1, 1); - - - gridLayout3->addLayout(gridLayout4, 1, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout3, 0, 1, 1, 1); - - gridLayout5 = new QGridLayout(); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(0); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - TextLabel1 = new QLabel(GroupBox1); - TextLabel1->setObjectName(QString::fromUtf8("TextLabel1")); - QSizePolicy sizePolicy(static_cast(0), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(TextLabel1->sizePolicy().hasHeightForWidth()); - TextLabel1->setSizePolicy(sizePolicy); - TextLabel1->setWordWrap(false); - - gridLayout5->addWidget(TextLabel1, 0, 0, 1, 1); - - spacerItem1 = new QSpacerItem(0, 180, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout5->addItem(spacerItem1, 1, 2, 1, 1); - - PushButton1 = new QPushButton(GroupBox1); - PushButton1->setObjectName(QString::fromUtf8("PushButton1")); - QSizePolicy sizePolicy1(static_cast(0), static_cast(0)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(PushButton1->sizePolicy().hasHeightForWidth()); - PushButton1->setSizePolicy(sizePolicy1); - - gridLayout5->addWidget(PushButton1, 0, 1, 1, 1); - - LineEdit1 = new QLineEdit(GroupBox1); - LineEdit1->setObjectName(QString::fromUtf8("LineEdit1")); - QSizePolicy sizePolicy2(static_cast(3), static_cast(0)); - sizePolicy2.setHorizontalStretch(0); - sizePolicy2.setVerticalStretch(0); - sizePolicy2.setHeightForWidth(LineEdit1->sizePolicy().hasHeightForWidth()); - LineEdit1->setSizePolicy(sizePolicy2); - - gridLayout5->addWidget(LineEdit1, 0, 2, 1, 1); - - - gridLayout2->addLayout(gridLayout5, 0, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupBox1, 0, 0, 1, 1); - - - retranslateUi(EntityGUI_1Sel_QTD); - - QSize size(329, 112); - size = size.expandedTo(EntityGUI_1Sel_QTD->minimumSizeHint()); - EntityGUI_1Sel_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_1Sel_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_1Sel_QTD) - { - EntityGUI_1Sel_QTD->setWindowTitle(QApplication::translate("EntityGUI_1Sel_QTD", "EntityGUI_1Sel_QTD", 0, QApplication::UnicodeUTF8)); - GroupBox1->setTitle(QApplication::translate("EntityGUI_1Sel_QTD", "Values", 0, QApplication::UnicodeUTF8)); - buttonApply->setText(QApplication::translate("EntityGUI_1Sel_QTD", "Create", 0, QApplication::UnicodeUTF8)); - buttonRedo->setText(QApplication::translate("EntityGUI_1Sel_QTD", "Redo", 0, QApplication::UnicodeUTF8)); - buttonUndo->setText(QApplication::translate("EntityGUI_1Sel_QTD", "Undo", 0, QApplication::UnicodeUTF8)); - TextLabel1->setText(QApplication::translate("EntityGUI_1Sel_QTD", "TL1", 0, QApplication::UnicodeUTF8)); - PushButton1->setText(QString()); - Q_UNUSED(EntityGUI_1Sel_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_1Sel_QTD: public Ui_EntityGUI_1Sel_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_1SEL_QTD_H diff --git a/src/EntityGUI/EntityGUI_1Sel_QTD.ui b/src/EntityGUI/EntityGUI_1Sel_QTD.ui new file mode 100644 index 000000000..b5af6d132 --- /dev/null +++ b/src/EntityGUI/EntityGUI_1Sel_QTD.ui @@ -0,0 +1,126 @@ + + EntityGUI_1Sel_QTD + + + + 0 + 0 + 402 + 88 + + + + EntityGUI_1Sel_QTD + + + + 0 + + + 0 + + + + + Values + + + + 9 + + + 6 + + + + + 0 + + + 6 + + + + + Undo + + + + + + + Redo + + + + + + + + + + 3 + 0 + 0 + 0 + + + + + + + + + 0 + 0 + 0 + 0 + + + + TL1 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + + + + + + + + Create + + + + + + + + + + qPixmapFromMimeSource + + PushButton1 + LineEdit1 + buttonApply + buttonUndo + buttonRedo + + + + diff --git a/src/EntityGUI/EntityGUI_1Spin.cxx b/src/EntityGUI/EntityGUI_1Spin.cxx deleted file mode 100644 index 14bbb116c..000000000 --- a/src/EntityGUI/EntityGUI_1Spin.cxx +++ /dev/null @@ -1,59 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_1Spin.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#include "EntityGUI_1Spin.h" - -#include "DlgRef_SpinBox.h" - -/* - * Constructs a EntityGUI_1Spin which is a child of 'parent', with the - * name 'name' and widget flags set to 'f' - */ -EntityGUI_1Spin::EntityGUI_1Spin(QWidget* parent, const char* name, Qt::WindowFlags fl) - :QWidget(parent, fl) -{ - setupUi(this); - - setObjectName(name); - - SpinBox1->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox1->close(); - - SpinBox_DX = new DlgRef_SpinBox(GroupBox1, "SpinBox_DX"); - gridLayout3->addWidget(SpinBox_DX, 0, 1); - -} - - -/* - * Destroys the object and frees any allocated resources - */ -EntityGUI_1Spin::~EntityGUI_1Spin() -{ - // no need to delete child widgets, Qt does it all for us -} diff --git a/src/EntityGUI/EntityGUI_1Spin.h b/src/EntityGUI/EntityGUI_1Spin.h deleted file mode 100644 index a2e17112d..000000000 --- a/src/EntityGUI/EntityGUI_1Spin.h +++ /dev/null @@ -1,50 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_1Spin.h -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#ifndef ENTITYGUI_1SPIN_H -#define ENTITYGUI_1SPIN_H - -#include "GEOM_EntityGUI.hxx" - -#include "EntityGUI_1Spin_QTD.h" - -class DlgRef_SpinBox; - -class GEOM_ENTITYGUI_EXPORT EntityGUI_1Spin : public QWidget, public Ui::EntityGUI_1Spin_QTD -{ - Q_OBJECT - -public: - EntityGUI_1Spin(QWidget* parent = 0, const char* name = 0, Qt::WindowFlags fl = 0); - ~EntityGUI_1Spin(); - - DlgRef_SpinBox* SpinBox_DX; - -}; - -#endif // ENTITYGUI_1SPIN_H diff --git a/src/EntityGUI/EntityGUI_1Spin_QTD.h b/src/EntityGUI/EntityGUI_1Spin_QTD.h deleted file mode 100644 index 7ee33ee37..000000000 --- a/src/EntityGUI/EntityGUI_1Spin_QTD.h +++ /dev/null @@ -1,160 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_1Spin_QTD.ui' -** -** Created: Tue Jul 10 10:27:13 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_1SPIN_QTD_H -#define ENTITYGUI_1SPIN_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_1Spin_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupBox1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QGridLayout *gridLayout3; - QLabel *TextLabel1; - QSpinBox *SpinBox1; - QSpacerItem *spacerItem; - QGridLayout *gridLayout4; - QGridLayout *gridLayout5; - QPushButton *buttonRedo; - QPushButton *buttonUndo; - QPushButton *buttonApply; - QSpacerItem *spacerItem1; - - void setupUi(QWidget *EntityGUI_1Spin_QTD) - { - EntityGUI_1Spin_QTD->setObjectName(QString::fromUtf8("EntityGUI_1Spin_QTD")); - gridLayout = new QGridLayout(EntityGUI_1Spin_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupBox1 = new QGroupBox(EntityGUI_1Spin_QTD); - GroupBox1->setObjectName(QString::fromUtf8("GroupBox1")); - gridLayout1 = new QGridLayout(GroupBox1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - gridLayout3 = new QGridLayout(); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(0); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - TextLabel1 = new QLabel(GroupBox1); - TextLabel1->setObjectName(QString::fromUtf8("TextLabel1")); - QSizePolicy sizePolicy(static_cast(0), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(TextLabel1->sizePolicy().hasHeightForWidth()); - TextLabel1->setSizePolicy(sizePolicy); - TextLabel1->setWordWrap(false); - - gridLayout3->addWidget(TextLabel1, 0, 0, 1, 1); - - SpinBox1 = new QSpinBox(GroupBox1); - SpinBox1->setObjectName(QString::fromUtf8("SpinBox1")); - QSizePolicy sizePolicy1(static_cast(7), static_cast(0)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(SpinBox1->sizePolicy().hasHeightForWidth()); - SpinBox1->setSizePolicy(sizePolicy1); - - gridLayout3->addWidget(SpinBox1, 0, 1, 1, 1); - - spacerItem = new QSpacerItem(0, 82, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout3->addItem(spacerItem, 3, 1, 1, 1); - - - gridLayout2->addLayout(gridLayout3, 0, 0, 1, 1); - - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - gridLayout5 = new QGridLayout(); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(0); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - buttonRedo = new QPushButton(GroupBox1); - buttonRedo->setObjectName(QString::fromUtf8("buttonRedo")); - - gridLayout5->addWidget(buttonRedo, 0, 1, 1, 1); - - buttonUndo = new QPushButton(GroupBox1); - buttonUndo->setObjectName(QString::fromUtf8("buttonUndo")); - - gridLayout5->addWidget(buttonUndo, 0, 0, 1, 1); - - - gridLayout4->addLayout(gridLayout5, 1, 0, 1, 1); - - buttonApply = new QPushButton(GroupBox1); - buttonApply->setObjectName(QString::fromUtf8("buttonApply")); - - gridLayout4->addWidget(buttonApply, 0, 0, 1, 1); - - spacerItem1 = new QSpacerItem(0, 40, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout4->addItem(spacerItem1, 2, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout4, 0, 1, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupBox1, 0, 0, 1, 1); - - - retranslateUi(EntityGUI_1Spin_QTD); - - QSize size(255, 112); - size = size.expandedTo(EntityGUI_1Spin_QTD->minimumSizeHint()); - EntityGUI_1Spin_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_1Spin_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_1Spin_QTD) - { - EntityGUI_1Spin_QTD->setWindowTitle(QApplication::translate("EntityGUI_1Spin_QTD", "EntityGUI_1Spin_QTD", 0, QApplication::UnicodeUTF8)); - GroupBox1->setTitle(QApplication::translate("EntityGUI_1Spin_QTD", "Values", 0, QApplication::UnicodeUTF8)); - TextLabel1->setText(QApplication::translate("EntityGUI_1Spin_QTD", "TL1", 0, QApplication::UnicodeUTF8)); - buttonRedo->setText(QApplication::translate("EntityGUI_1Spin_QTD", "Redo", 0, QApplication::UnicodeUTF8)); - buttonUndo->setText(QApplication::translate("EntityGUI_1Spin_QTD", "Undo", 0, QApplication::UnicodeUTF8)); - buttonApply->setText(QApplication::translate("EntityGUI_1Spin_QTD", "Create", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_1Spin_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_1Spin_QTD: public Ui_EntityGUI_1Spin_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_1SPIN_QTD_H diff --git a/src/EntityGUI/EntityGUI_1Spin_QTD.ui b/src/EntityGUI/EntityGUI_1Spin_QTD.ui new file mode 100644 index 000000000..e9260a30b --- /dev/null +++ b/src/EntityGUI/EntityGUI_1Spin_QTD.ui @@ -0,0 +1,101 @@ + + EntityGUI_1Spin_QTD + + + + 0 + 0 + 268 + 88 + + + + EntityGUI_1Spin_QTD + + + + 0 + + + 0 + + + + + Values + + + + 9 + + + 6 + + + + + + + + 0 + + + 6 + + + + + Redo + + + + + + + Undo + + + + + + + + + Create + + + + + + + + 0 + 0 + 0 + 0 + + + + TL1 + + + false + + + + + + + + + + qPixmapFromMimeSource + + SpinBox_DX + buttonApply + buttonUndo + buttonRedo + + + + diff --git a/src/EntityGUI/EntityGUI_2Spin.cxx b/src/EntityGUI/EntityGUI_2Spin.cxx deleted file mode 100644 index 5882b36e9..000000000 --- a/src/EntityGUI/EntityGUI_2Spin.cxx +++ /dev/null @@ -1,64 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_2Spin.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#include "EntityGUI_2Spin.h" - -#include "DlgRef_SpinBox.h" - -/* - * Constructs a EntityGUI_2Spin which is a child of 'parent', with the - * name 'name' and widget flags set to 'f' - */ -EntityGUI_2Spin::EntityGUI_2Spin(QWidget* parent, const char* name, Qt::WindowFlags fl) - :QWidget(parent, fl) -{ - setupUi(this); - - setObjectName(name); - - SpinBox1->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox1->close(); - SpinBox2->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox2->close(); - - SpinBox_DX = new DlgRef_SpinBox(GroupBox1, "SpinBox_DX"); - gridLayout3->addWidget(SpinBox_DX, 0, 1); - - SpinBox_DY = new DlgRef_SpinBox(GroupBox1, "SpinBox_DY"); - gridLayout3->addWidget(SpinBox_DY, 1, 1); - -} - - -/* - * Destroys the object and frees any allocated resources - */ -EntityGUI_2Spin::~EntityGUI_2Spin() -{ - // no need to delete child widgets, Qt does it all for us -} diff --git a/src/EntityGUI/EntityGUI_2Spin.h b/src/EntityGUI/EntityGUI_2Spin.h deleted file mode 100644 index 5bf0e6171..000000000 --- a/src/EntityGUI/EntityGUI_2Spin.h +++ /dev/null @@ -1,51 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_2Spin.h -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#ifndef ENTITYGUI_2SPIN_H -#define ENTITYGUI_2SPIN_H - -#include "GEOM_EntityGUI.hxx" - -#include "EntityGUI_2Spin_QTD.h" - -class DlgRef_SpinBox; - -class GEOM_ENTITYGUI_EXPORT EntityGUI_2Spin : public QWidget, public Ui::EntityGUI_2Spin_QTD -{ - Q_OBJECT - -public: - EntityGUI_2Spin(QWidget* parent = 0, const char* name = 0, Qt::WindowFlags fl = 0); - ~EntityGUI_2Spin(); - - DlgRef_SpinBox* SpinBox_DX; - DlgRef_SpinBox* SpinBox_DY; - -}; - -#endif // ENTITYGUI_2SPIN_H diff --git a/src/EntityGUI/EntityGUI_2Spin_QTD.h b/src/EntityGUI/EntityGUI_2Spin_QTD.h deleted file mode 100644 index 094f9c25f..000000000 --- a/src/EntityGUI/EntityGUI_2Spin_QTD.h +++ /dev/null @@ -1,184 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_2Spin_QTD.ui' -** -** Created: Tue Jul 10 10:30:02 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_2SPIN_QTD_H -#define ENTITYGUI_2SPIN_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_2Spin_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupBox1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QGridLayout *gridLayout3; - QLabel *TextLabel2; - QLabel *TextLabel1; - QSpinBox *SpinBox1; - QSpinBox *SpinBox2; - QSpacerItem *spacerItem; - QGridLayout *gridLayout4; - QSpacerItem *spacerItem1; - QGridLayout *gridLayout5; - QPushButton *buttonUndo; - QPushButton *buttonRedo; - QPushButton *buttonApply; - - void setupUi(QWidget *EntityGUI_2Spin_QTD) - { - EntityGUI_2Spin_QTD->setObjectName(QString::fromUtf8("EntityGUI_2Spin_QTD")); - gridLayout = new QGridLayout(EntityGUI_2Spin_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupBox1 = new QGroupBox(EntityGUI_2Spin_QTD); - GroupBox1->setObjectName(QString::fromUtf8("GroupBox1")); - gridLayout1 = new QGridLayout(GroupBox1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - gridLayout3 = new QGridLayout(); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(0); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - TextLabel2 = new QLabel(GroupBox1); - TextLabel2->setObjectName(QString::fromUtf8("TextLabel2")); - QSizePolicy sizePolicy(static_cast(0), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(TextLabel2->sizePolicy().hasHeightForWidth()); - TextLabel2->setSizePolicy(sizePolicy); - TextLabel2->setWordWrap(false); - - gridLayout3->addWidget(TextLabel2, 1, 0, 1, 1); - - TextLabel1 = new QLabel(GroupBox1); - TextLabel1->setObjectName(QString::fromUtf8("TextLabel1")); - QSizePolicy sizePolicy1(static_cast(0), static_cast(0)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(TextLabel1->sizePolicy().hasHeightForWidth()); - TextLabel1->setSizePolicy(sizePolicy1); - TextLabel1->setWordWrap(false); - - gridLayout3->addWidget(TextLabel1, 0, 0, 1, 1); - - SpinBox1 = new QSpinBox(GroupBox1); - SpinBox1->setObjectName(QString::fromUtf8("SpinBox1")); - QSizePolicy sizePolicy2(static_cast(7), static_cast(0)); - sizePolicy2.setHorizontalStretch(0); - sizePolicy2.setVerticalStretch(0); - sizePolicy2.setHeightForWidth(SpinBox1->sizePolicy().hasHeightForWidth()); - SpinBox1->setSizePolicy(sizePolicy2); - - gridLayout3->addWidget(SpinBox1, 0, 1, 1, 1); - - SpinBox2 = new QSpinBox(GroupBox1); - SpinBox2->setObjectName(QString::fromUtf8("SpinBox2")); - QSizePolicy sizePolicy3(static_cast(7), static_cast(0)); - sizePolicy3.setHorizontalStretch(0); - sizePolicy3.setVerticalStretch(0); - sizePolicy3.setHeightForWidth(SpinBox2->sizePolicy().hasHeightForWidth()); - SpinBox2->setSizePolicy(sizePolicy3); - - gridLayout3->addWidget(SpinBox2, 1, 1, 1, 1); - - spacerItem = new QSpacerItem(0, 82, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout3->addItem(spacerItem, 3, 1, 1, 1); - - - gridLayout2->addLayout(gridLayout3, 0, 0, 1, 1); - - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - spacerItem1 = new QSpacerItem(0, 51, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout4->addItem(spacerItem1, 2, 0, 1, 1); - - gridLayout5 = new QGridLayout(); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(0); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - buttonUndo = new QPushButton(GroupBox1); - buttonUndo->setObjectName(QString::fromUtf8("buttonUndo")); - - gridLayout5->addWidget(buttonUndo, 0, 0, 1, 1); - - buttonRedo = new QPushButton(GroupBox1); - buttonRedo->setObjectName(QString::fromUtf8("buttonRedo")); - - gridLayout5->addWidget(buttonRedo, 0, 1, 1, 1); - - - gridLayout4->addLayout(gridLayout5, 1, 0, 1, 1); - - buttonApply = new QPushButton(GroupBox1); - buttonApply->setObjectName(QString::fromUtf8("buttonApply")); - - gridLayout4->addWidget(buttonApply, 0, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout4, 0, 1, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupBox1, 0, 0, 1, 1); - - - retranslateUi(EntityGUI_2Spin_QTD); - - QSize size(255, 112); - size = size.expandedTo(EntityGUI_2Spin_QTD->minimumSizeHint()); - EntityGUI_2Spin_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_2Spin_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_2Spin_QTD) - { - EntityGUI_2Spin_QTD->setWindowTitle(QApplication::translate("EntityGUI_2Spin_QTD", "EntityGUI_2Spin_QTD", 0, QApplication::UnicodeUTF8)); - GroupBox1->setTitle(QApplication::translate("EntityGUI_2Spin_QTD", "Values", 0, QApplication::UnicodeUTF8)); - TextLabel2->setText(QApplication::translate("EntityGUI_2Spin_QTD", "TL2", 0, QApplication::UnicodeUTF8)); - TextLabel1->setText(QApplication::translate("EntityGUI_2Spin_QTD", "TL1", 0, QApplication::UnicodeUTF8)); - buttonUndo->setText(QApplication::translate("EntityGUI_2Spin_QTD", "Undo", 0, QApplication::UnicodeUTF8)); - buttonRedo->setText(QApplication::translate("EntityGUI_2Spin_QTD", "Redo", 0, QApplication::UnicodeUTF8)); - buttonApply->setText(QApplication::translate("EntityGUI_2Spin_QTD", "Create", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_2Spin_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_2Spin_QTD: public Ui_EntityGUI_2Spin_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_2SPIN_QTD_H diff --git a/src/EntityGUI/EntityGUI_2Spin_QTD.ui b/src/EntityGUI/EntityGUI_2Spin_QTD.ui new file mode 100644 index 000000000..61378e2d7 --- /dev/null +++ b/src/EntityGUI/EntityGUI_2Spin_QTD.ui @@ -0,0 +1,123 @@ + + EntityGUI_2Spin_QTD + + + + 0 + 0 + 264 + 88 + + + + EntityGUI_2Spin_QTD + + + + 0 + + + 0 + + + + + Values + + + + 9 + + + 6 + + + + + + + + + + + + 0 + 0 + 0 + 0 + + + + TL2 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL1 + + + false + + + + + + + 0 + + + 6 + + + + + Undo + + + + + + + Redo + + + + + + + + + Create + + + + + + + + + + qPixmapFromMimeSource + + SpinBox_DX + SpinBox_DY + buttonApply + buttonUndo + buttonRedo + + + + diff --git a/src/EntityGUI/EntityGUI_3Spin.cxx b/src/EntityGUI/EntityGUI_3Spin.cxx deleted file mode 100644 index da1c8d05e..000000000 --- a/src/EntityGUI/EntityGUI_3Spin.cxx +++ /dev/null @@ -1,68 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_3Spin.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#include "EntityGUI_3Spin.h" - -#include "DlgRef_SpinBox.h" - -/* - * Constructs a EntityGUI_3Spin which is a child of 'parent', with the - * name 'name' and widget flags set to 'f' - */ -EntityGUI_3Spin::EntityGUI_3Spin(QWidget* parent, const char* name, Qt::WindowFlags fl) - :QWidget(parent, fl) -{ - setupUi(this); - - setObjectName(name); - - SpinBox1->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox1->close(); - SpinBox2->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox2->close(); - SpinBox3->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox3->close(); - - SpinBox_DX = new DlgRef_SpinBox(GroupBox1, "SpinBox_DX"); - gridLayout5->addWidget(SpinBox_DX, 0, 1); - - SpinBox_DY = new DlgRef_SpinBox(GroupBox1, "SpinBox_DY"); - gridLayout5->addWidget(SpinBox_DY, 1, 1); - - SpinBox_DZ = new DlgRef_SpinBox(GroupBox1, "SpinBox_DZ"); - gridLayout5->addWidget(SpinBox_DZ, 2, 1); -} - - -/* - * Destroys the object and frees any allocated resources - */ -EntityGUI_3Spin::~EntityGUI_3Spin() -{ - // no need to delete child widgets, Qt does it all for us -} diff --git a/src/EntityGUI/EntityGUI_3Spin.h b/src/EntityGUI/EntityGUI_3Spin.h deleted file mode 100644 index 8f1fbdc39..000000000 --- a/src/EntityGUI/EntityGUI_3Spin.h +++ /dev/null @@ -1,52 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_3Spin.h -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#ifndef ENTITYGUI_3SPIN_H -#define ENTITYGUI_3SPIN_H - -#include "GEOM_EntityGUI.hxx" - -#include "EntityGUI_3Spin_QTD.h" - -class DlgRef_SpinBox; - -class GEOM_ENTITYGUI_EXPORT EntityGUI_3Spin : public QWidget, public Ui::EntityGUI_3Spin_QTD -{ - Q_OBJECT - -public: - EntityGUI_3Spin( QWidget* parent = 0, const char* name = 0, Qt::WindowFlags fl = 0 ); - ~EntityGUI_3Spin(); - - DlgRef_SpinBox* SpinBox_DX; - DlgRef_SpinBox* SpinBox_DY; - DlgRef_SpinBox* SpinBox_DZ; - -}; - -#endif // ENTITYGUI_3SPIN_H diff --git a/src/EntityGUI/EntityGUI_3Spin_QTD.h b/src/EntityGUI/EntityGUI_3Spin_QTD.h deleted file mode 100644 index 80811fa68..000000000 --- a/src/EntityGUI/EntityGUI_3Spin_QTD.h +++ /dev/null @@ -1,208 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_3Spin_QTD.ui' -** -** Created: Tue Jul 10 10:33:45 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_3SPIN_QTD_H -#define ENTITYGUI_3SPIN_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_3Spin_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupBox1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QGridLayout *gridLayout3; - QPushButton *buttonApply; - QSpacerItem *spacerItem; - QGridLayout *gridLayout4; - QPushButton *buttonUndo; - QPushButton *buttonRedo; - QGridLayout *gridLayout5; - QLabel *TextLabel2; - QLabel *TextLabel1; - QSpinBox *SpinBox1; - QSpinBox *SpinBox2; - QLabel *TextLabel3; - QSpacerItem *spacerItem1; - QSpinBox *SpinBox3; - - void setupUi(QWidget *EntityGUI_3Spin_QTD) - { - EntityGUI_3Spin_QTD->setObjectName(QString::fromUtf8("EntityGUI_3Spin_QTD")); - gridLayout = new QGridLayout(EntityGUI_3Spin_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupBox1 = new QGroupBox(EntityGUI_3Spin_QTD); - GroupBox1->setObjectName(QString::fromUtf8("GroupBox1")); - gridLayout1 = new QGridLayout(GroupBox1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - gridLayout3 = new QGridLayout(); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(0); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - buttonApply = new QPushButton(GroupBox1); - buttonApply->setObjectName(QString::fromUtf8("buttonApply")); - - gridLayout3->addWidget(buttonApply, 0, 0, 1, 1); - - spacerItem = new QSpacerItem(0, 121, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout3->addItem(spacerItem, 2, 0, 1, 1); - - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - buttonUndo = new QPushButton(GroupBox1); - buttonUndo->setObjectName(QString::fromUtf8("buttonUndo")); - - gridLayout4->addWidget(buttonUndo, 0, 0, 1, 1); - - buttonRedo = new QPushButton(GroupBox1); - buttonRedo->setObjectName(QString::fromUtf8("buttonRedo")); - - gridLayout4->addWidget(buttonRedo, 0, 1, 1, 1); - - - gridLayout3->addLayout(gridLayout4, 1, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout3, 0, 1, 1, 1); - - gridLayout5 = new QGridLayout(); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(0); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - TextLabel2 = new QLabel(GroupBox1); - TextLabel2->setObjectName(QString::fromUtf8("TextLabel2")); - QSizePolicy sizePolicy(static_cast(0), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(TextLabel2->sizePolicy().hasHeightForWidth()); - TextLabel2->setSizePolicy(sizePolicy); - TextLabel2->setWordWrap(false); - - gridLayout5->addWidget(TextLabel2, 1, 0, 1, 1); - - TextLabel1 = new QLabel(GroupBox1); - TextLabel1->setObjectName(QString::fromUtf8("TextLabel1")); - QSizePolicy sizePolicy1(static_cast(0), static_cast(0)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(TextLabel1->sizePolicy().hasHeightForWidth()); - TextLabel1->setSizePolicy(sizePolicy1); - TextLabel1->setWordWrap(false); - - gridLayout5->addWidget(TextLabel1, 0, 0, 1, 1); - - SpinBox1 = new QSpinBox(GroupBox1); - SpinBox1->setObjectName(QString::fromUtf8("SpinBox1")); - QSizePolicy sizePolicy2(static_cast(7), static_cast(0)); - sizePolicy2.setHorizontalStretch(0); - sizePolicy2.setVerticalStretch(0); - sizePolicy2.setHeightForWidth(SpinBox1->sizePolicy().hasHeightForWidth()); - SpinBox1->setSizePolicy(sizePolicy2); - - gridLayout5->addWidget(SpinBox1, 0, 1, 1, 1); - - SpinBox2 = new QSpinBox(GroupBox1); - SpinBox2->setObjectName(QString::fromUtf8("SpinBox2")); - QSizePolicy sizePolicy3(static_cast(7), static_cast(0)); - sizePolicy3.setHorizontalStretch(0); - sizePolicy3.setVerticalStretch(0); - sizePolicy3.setHeightForWidth(SpinBox2->sizePolicy().hasHeightForWidth()); - SpinBox2->setSizePolicy(sizePolicy3); - - gridLayout5->addWidget(SpinBox2, 1, 1, 1, 1); - - TextLabel3 = new QLabel(GroupBox1); - TextLabel3->setObjectName(QString::fromUtf8("TextLabel3")); - QSizePolicy sizePolicy4(static_cast(0), static_cast(0)); - sizePolicy4.setHorizontalStretch(0); - sizePolicy4.setVerticalStretch(0); - sizePolicy4.setHeightForWidth(TextLabel3->sizePolicy().hasHeightForWidth()); - TextLabel3->setSizePolicy(sizePolicy4); - TextLabel3->setWordWrap(false); - - gridLayout5->addWidget(TextLabel3, 2, 0, 1, 1); - - spacerItem1 = new QSpacerItem(0, 82, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout5->addItem(spacerItem1, 3, 1, 1, 1); - - SpinBox3 = new QSpinBox(GroupBox1); - SpinBox3->setObjectName(QString::fromUtf8("SpinBox3")); - QSizePolicy sizePolicy5(static_cast(7), static_cast(0)); - sizePolicy5.setHorizontalStretch(0); - sizePolicy5.setVerticalStretch(0); - sizePolicy5.setHeightForWidth(SpinBox3->sizePolicy().hasHeightForWidth()); - SpinBox3->setSizePolicy(sizePolicy5); - - gridLayout5->addWidget(SpinBox3, 2, 1, 1, 1); - - - gridLayout2->addLayout(gridLayout5, 0, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupBox1, 0, 0, 1, 1); - - - retranslateUi(EntityGUI_3Spin_QTD); - - QSize size(255, 125); - size = size.expandedTo(EntityGUI_3Spin_QTD->minimumSizeHint()); - EntityGUI_3Spin_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_3Spin_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_3Spin_QTD) - { - EntityGUI_3Spin_QTD->setWindowTitle(QApplication::translate("EntityGUI_3Spin_QTD", "EntityGUI_3Spin_QTD", 0, QApplication::UnicodeUTF8)); - GroupBox1->setTitle(QApplication::translate("EntityGUI_3Spin_QTD", "Values", 0, QApplication::UnicodeUTF8)); - buttonApply->setText(QApplication::translate("EntityGUI_3Spin_QTD", "Create", 0, QApplication::UnicodeUTF8)); - buttonUndo->setText(QApplication::translate("EntityGUI_3Spin_QTD", "Undo", 0, QApplication::UnicodeUTF8)); - buttonRedo->setText(QApplication::translate("EntityGUI_3Spin_QTD", "Redo", 0, QApplication::UnicodeUTF8)); - TextLabel2->setText(QApplication::translate("EntityGUI_3Spin_QTD", "TL2", 0, QApplication::UnicodeUTF8)); - TextLabel1->setText(QApplication::translate("EntityGUI_3Spin_QTD", "TL1", 0, QApplication::UnicodeUTF8)); - TextLabel3->setText(QApplication::translate("EntityGUI_3Spin_QTD", "TL3", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_3Spin_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_3Spin_QTD: public Ui_EntityGUI_3Spin_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_3SPIN_QTD_H diff --git a/src/EntityGUI/EntityGUI_3Spin_QTD.ui b/src/EntityGUI/EntityGUI_3Spin_QTD.ui new file mode 100644 index 000000000..907eebc6e --- /dev/null +++ b/src/EntityGUI/EntityGUI_3Spin_QTD.ui @@ -0,0 +1,145 @@ + + EntityGUI_3Spin_QTD + + + + 0 + 0 + 264 + 114 + + + + EntityGUI_3Spin_QTD + + + + 0 + + + 0 + + + + + Values + + + + 9 + + + 6 + + + + + + + + 0 + + + 6 + + + + + Undo + + + + + + + Redo + + + + + + + + + Create + + + + + + + + + + + + + + 0 + 0 + 0 + 0 + + + + TL1 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL2 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL3 + + + false + + + + + + + + + + qPixmapFromMimeSource + + SpinBox_DX + SpinBox_DY + SpinBox_DZ + buttonApply + buttonUndo + buttonRedo + + + + diff --git a/src/EntityGUI/EntityGUI_4Spin.cxx b/src/EntityGUI/EntityGUI_4Spin.cxx deleted file mode 100644 index 4f5e888bc..000000000 --- a/src/EntityGUI/EntityGUI_4Spin.cxx +++ /dev/null @@ -1,73 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_4Spin.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#include "EntityGUI_4Spin.h" - -#include "DlgRef_SpinBox.h" - -/* - * Constructs a EntityGUI_4Spin which is a child of 'parent', with the - * name 'name' and widget flags set to 'f' - */ -EntityGUI_4Spin::EntityGUI_4Spin(QWidget* parent, const char* name, Qt::WindowFlags fl) - :QWidget(parent, fl) -{ - setupUi(this); - - setObjectName(name); - - SpinBox1->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox1->close(); - SpinBox2->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox2->close(); - SpinBox3->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox3->close(); - SpinBox4->setAttribute( Qt::WA_DeleteOnClose ); - SpinBox4->close(); - - SpinBox_DX = new DlgRef_SpinBox(GroupBox1, "SpinBox_DX"); - gridLayout5->addWidget(SpinBox_DX, 0, 1); - - SpinBox_DY = new DlgRef_SpinBox(GroupBox1, "SpinBox_DY"); - gridLayout5->addWidget(SpinBox_DY, 1, 1); - - SpinBox_DZ = new DlgRef_SpinBox(GroupBox1, "SpinBox_DZ"); - gridLayout5->addWidget(SpinBox_DZ, 2, 1); - - SpinBox_DS = new DlgRef_SpinBox(GroupBox1, "SpinBox_DS"); - gridLayout5->addWidget(SpinBox_DS, 3, 1); -} - - -/* - * Destroys the object and frees any allocated resources - */ -EntityGUI_4Spin::~EntityGUI_4Spin() -{ - // no need to delete child widgets, Qt does it all for us -} diff --git a/src/EntityGUI/EntityGUI_4Spin.h b/src/EntityGUI/EntityGUI_4Spin.h deleted file mode 100644 index dcd5c6b14..000000000 --- a/src/EntityGUI/EntityGUI_4Spin.h +++ /dev/null @@ -1,53 +0,0 @@ -// GEOM GEOMGUI : GUI for Geometry component -// -// Copyright (C) 2003 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 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 -// -// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -// -// -// -// File : EntityGUI_4Spin.h -// Author : Damien COQUERET -// Module : GEOM -// $Header: - -#ifndef ENTITYGUI_4SPIN_H -#define ENTITYGUI_4SPIN_H - -#include "GEOM_EntityGUI.hxx" - -#include "EntityGUI_4Spin_QTD.h" - -class DlgRef_SpinBox; - -class GEOM_ENTITYGUI_EXPORT EntityGUI_4Spin : public QWidget, public Ui::EntityGUI_4Spin_QTD -{ - Q_OBJECT - -public: - EntityGUI_4Spin( QWidget* parent = 0, const char* name = 0, Qt::WindowFlags fl = 0 ); - ~EntityGUI_4Spin(); - - DlgRef_SpinBox* SpinBox_DX; - DlgRef_SpinBox* SpinBox_DY; - DlgRef_SpinBox* SpinBox_DZ; - DlgRef_SpinBox* SpinBox_DS; - -}; - -#endif // ENTITYGUI_4SPIN_H diff --git a/src/EntityGUI/EntityGUI_4Spin_QTD.h b/src/EntityGUI/EntityGUI_4Spin_QTD.h deleted file mode 100644 index 457de0b39..000000000 --- a/src/EntityGUI/EntityGUI_4Spin_QTD.h +++ /dev/null @@ -1,232 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_4Spin_QTD.ui' -** -** Created: Tue Jul 10 10:35:47 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_4SPIN_QTD_H -#define ENTITYGUI_4SPIN_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_4Spin_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupBox1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QGridLayout *gridLayout3; - QGridLayout *gridLayout4; - QPushButton *buttonRedo; - QPushButton *buttonUndo; - QSpacerItem *spacerItem; - QPushButton *buttonApply; - QGridLayout *gridLayout5; - QSpinBox *SpinBox3; - QSpinBox *SpinBox2; - QLabel *TextLabel2; - QSpacerItem *spacerItem1; - QSpinBox *SpinBox4; - QLabel *TextLabel3; - QSpinBox *SpinBox1; - QLabel *TextLabel1; - QLabel *TextLabel4; - - void setupUi(QWidget *EntityGUI_4Spin_QTD) - { - EntityGUI_4Spin_QTD->setObjectName(QString::fromUtf8("EntityGUI_4Spin_QTD")); - gridLayout = new QGridLayout(EntityGUI_4Spin_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupBox1 = new QGroupBox(EntityGUI_4Spin_QTD); - GroupBox1->setObjectName(QString::fromUtf8("GroupBox1")); - gridLayout1 = new QGridLayout(GroupBox1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - gridLayout3 = new QGridLayout(); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(0); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - buttonRedo = new QPushButton(GroupBox1); - buttonRedo->setObjectName(QString::fromUtf8("buttonRedo")); - - gridLayout4->addWidget(buttonRedo, 0, 1, 1, 1); - - buttonUndo = new QPushButton(GroupBox1); - buttonUndo->setObjectName(QString::fromUtf8("buttonUndo")); - - gridLayout4->addWidget(buttonUndo, 0, 0, 1, 1); - - - gridLayout3->addLayout(gridLayout4, 1, 0, 1, 1); - - spacerItem = new QSpacerItem(0, 45, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout3->addItem(spacerItem, 2, 0, 1, 1); - - buttonApply = new QPushButton(GroupBox1); - buttonApply->setObjectName(QString::fromUtf8("buttonApply")); - - gridLayout3->addWidget(buttonApply, 0, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout3, 0, 1, 1, 1); - - gridLayout5 = new QGridLayout(); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(0); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - SpinBox3 = new QSpinBox(GroupBox1); - SpinBox3->setObjectName(QString::fromUtf8("SpinBox3")); - QSizePolicy sizePolicy(static_cast(7), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(SpinBox3->sizePolicy().hasHeightForWidth()); - SpinBox3->setSizePolicy(sizePolicy); - - gridLayout5->addWidget(SpinBox3, 2, 1, 1, 1); - - SpinBox2 = new QSpinBox(GroupBox1); - SpinBox2->setObjectName(QString::fromUtf8("SpinBox2")); - QSizePolicy sizePolicy1(static_cast(7), static_cast(0)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(SpinBox2->sizePolicy().hasHeightForWidth()); - SpinBox2->setSizePolicy(sizePolicy1); - - gridLayout5->addWidget(SpinBox2, 1, 1, 1, 1); - - TextLabel2 = new QLabel(GroupBox1); - TextLabel2->setObjectName(QString::fromUtf8("TextLabel2")); - QSizePolicy sizePolicy2(static_cast(0), static_cast(0)); - sizePolicy2.setHorizontalStretch(0); - sizePolicy2.setVerticalStretch(0); - sizePolicy2.setHeightForWidth(TextLabel2->sizePolicy().hasHeightForWidth()); - TextLabel2->setSizePolicy(sizePolicy2); - TextLabel2->setWordWrap(false); - - gridLayout5->addWidget(TextLabel2, 1, 0, 1, 1); - - spacerItem1 = new QSpacerItem(0, 70, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout5->addItem(spacerItem1, 4, 1, 1, 1); - - SpinBox4 = new QSpinBox(GroupBox1); - SpinBox4->setObjectName(QString::fromUtf8("SpinBox4")); - QSizePolicy sizePolicy3(static_cast(7), static_cast(0)); - sizePolicy3.setHorizontalStretch(0); - sizePolicy3.setVerticalStretch(0); - sizePolicy3.setHeightForWidth(SpinBox4->sizePolicy().hasHeightForWidth()); - SpinBox4->setSizePolicy(sizePolicy3); - - gridLayout5->addWidget(SpinBox4, 3, 1, 1, 1); - - TextLabel3 = new QLabel(GroupBox1); - TextLabel3->setObjectName(QString::fromUtf8("TextLabel3")); - QSizePolicy sizePolicy4(static_cast(0), static_cast(0)); - sizePolicy4.setHorizontalStretch(0); - sizePolicy4.setVerticalStretch(0); - sizePolicy4.setHeightForWidth(TextLabel3->sizePolicy().hasHeightForWidth()); - TextLabel3->setSizePolicy(sizePolicy4); - TextLabel3->setWordWrap(false); - - gridLayout5->addWidget(TextLabel3, 2, 0, 1, 1); - - SpinBox1 = new QSpinBox(GroupBox1); - SpinBox1->setObjectName(QString::fromUtf8("SpinBox1")); - QSizePolicy sizePolicy5(static_cast(7), static_cast(0)); - sizePolicy5.setHorizontalStretch(0); - sizePolicy5.setVerticalStretch(0); - sizePolicy5.setHeightForWidth(SpinBox1->sizePolicy().hasHeightForWidth()); - SpinBox1->setSizePolicy(sizePolicy5); - - gridLayout5->addWidget(SpinBox1, 0, 1, 1, 1); - - TextLabel1 = new QLabel(GroupBox1); - TextLabel1->setObjectName(QString::fromUtf8("TextLabel1")); - QSizePolicy sizePolicy6(static_cast(0), static_cast(0)); - sizePolicy6.setHorizontalStretch(0); - sizePolicy6.setVerticalStretch(0); - sizePolicy6.setHeightForWidth(TextLabel1->sizePolicy().hasHeightForWidth()); - TextLabel1->setSizePolicy(sizePolicy6); - TextLabel1->setWordWrap(false); - - gridLayout5->addWidget(TextLabel1, 0, 0, 1, 1); - - TextLabel4 = new QLabel(GroupBox1); - TextLabel4->setObjectName(QString::fromUtf8("TextLabel4")); - QSizePolicy sizePolicy7(static_cast(0), static_cast(0)); - sizePolicy7.setHorizontalStretch(0); - sizePolicy7.setVerticalStretch(0); - sizePolicy7.setHeightForWidth(TextLabel4->sizePolicy().hasHeightForWidth()); - TextLabel4->setSizePolicy(sizePolicy7); - TextLabel4->setWordWrap(false); - - gridLayout5->addWidget(TextLabel4, 3, 0, 1, 1); - - - gridLayout2->addLayout(gridLayout5, 0, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupBox1, 0, 0, 1, 1); - - - retranslateUi(EntityGUI_4Spin_QTD); - - QSize size(255, 154); - size = size.expandedTo(EntityGUI_4Spin_QTD->minimumSizeHint()); - EntityGUI_4Spin_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_4Spin_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_4Spin_QTD) - { - EntityGUI_4Spin_QTD->setWindowTitle(QApplication::translate("EntityGUI_4Spin_QTD", "EntityGUI_4Spin_QTD", 0, QApplication::UnicodeUTF8)); - GroupBox1->setTitle(QApplication::translate("EntityGUI_4Spin_QTD", "Values", 0, QApplication::UnicodeUTF8)); - buttonRedo->setText(QApplication::translate("EntityGUI_4Spin_QTD", "Redo", 0, QApplication::UnicodeUTF8)); - buttonUndo->setText(QApplication::translate("EntityGUI_4Spin_QTD", "Undo", 0, QApplication::UnicodeUTF8)); - buttonApply->setText(QApplication::translate("EntityGUI_4Spin_QTD", "Create", 0, QApplication::UnicodeUTF8)); - TextLabel2->setText(QApplication::translate("EntityGUI_4Spin_QTD", "TL2", 0, QApplication::UnicodeUTF8)); - TextLabel3->setText(QApplication::translate("EntityGUI_4Spin_QTD", "TL3", 0, QApplication::UnicodeUTF8)); - TextLabel1->setText(QApplication::translate("EntityGUI_4Spin_QTD", "TL1", 0, QApplication::UnicodeUTF8)); - TextLabel4->setText(QApplication::translate("EntityGUI_4Spin_QTD", "TL4", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_4Spin_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_4Spin_QTD: public Ui_EntityGUI_4Spin_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_4SPIN_QTD_H diff --git a/src/EntityGUI/EntityGUI_4Spin_QTD.ui b/src/EntityGUI/EntityGUI_4Spin_QTD.ui new file mode 100644 index 000000000..279969008 --- /dev/null +++ b/src/EntityGUI/EntityGUI_4Spin_QTD.ui @@ -0,0 +1,167 @@ + + EntityGUI_4Spin_QTD + + + + 0 + 0 + 264 + 140 + + + + EntityGUI_4Spin_QTD + + + + 0 + + + 0 + + + + + Values + + + + 9 + + + 6 + + + + + + + + + + + + + + + + + 0 + + + 6 + + + + + Redo + + + + + + + Undo + + + + + + + + + Create + + + + + + + + 0 + 0 + 0 + 0 + + + + TL1 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL4 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL2 + + + false + + + + + + + + 0 + 0 + 0 + 0 + + + + TL3 + + + false + + + + + + + + + + qPixmapFromMimeSource + + SpinBox_DX + SpinBox_DY + SpinBox_DZ + SpinBox_DS + buttonApply + buttonUndo + buttonRedo + + + + diff --git a/src/EntityGUI/EntityGUI_Dir1_QTD.h b/src/EntityGUI/EntityGUI_Dir1_QTD.h deleted file mode 100644 index 6231eca61..000000000 --- a/src/EntityGUI/EntityGUI_Dir1_QTD.h +++ /dev/null @@ -1,114 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_Dir1_QTD.ui' -** -** Created: Tue Jul 10 10:20:45 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_DIR1_QTD_H -#define ENTITYGUI_DIR1_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_Dir1_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupDir1; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QRadioButton *RB_Dir12; - QRadioButton *RB_Dir13; - QRadioButton *RB_Dir11; - QRadioButton *RB_Dir14; - - void setupUi(QWidget *EntityGUI_Dir1_QTD) - { - EntityGUI_Dir1_QTD->setObjectName(QString::fromUtf8("EntityGUI_Dir1_QTD")); - gridLayout = new QGridLayout(EntityGUI_Dir1_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupDir1 = new QGroupBox(EntityGUI_Dir1_QTD); - GroupDir1->setObjectName(QString::fromUtf8("GroupDir1")); - QSizePolicy sizePolicy(static_cast(7), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(GroupDir1->sizePolicy().hasHeightForWidth()); - GroupDir1->setSizePolicy(sizePolicy); - gridLayout1 = new QGridLayout(GroupDir1); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - RB_Dir12 = new QRadioButton(GroupDir1); - RB_Dir12->setObjectName(QString::fromUtf8("RB_Dir12")); - - gridLayout2->addWidget(RB_Dir12, 1, 0, 1, 1); - - RB_Dir13 = new QRadioButton(GroupDir1); - RB_Dir13->setObjectName(QString::fromUtf8("RB_Dir13")); - - gridLayout2->addWidget(RB_Dir13, 2, 0, 1, 1); - - RB_Dir11 = new QRadioButton(GroupDir1); - RB_Dir11->setObjectName(QString::fromUtf8("RB_Dir11")); - - gridLayout2->addWidget(RB_Dir11, 0, 0, 1, 1); - - RB_Dir14 = new QRadioButton(GroupDir1); - RB_Dir14->setObjectName(QString::fromUtf8("RB_Dir14")); - - gridLayout2->addWidget(RB_Dir14, 3, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupDir1, 0, 0, 1, 1); - - QWidget::setTabOrder(RB_Dir11, RB_Dir12); - QWidget::setTabOrder(RB_Dir12, RB_Dir13); - QWidget::setTabOrder(RB_Dir13, RB_Dir14); - - retranslateUi(EntityGUI_Dir1_QTD); - - QSize size(131, 123); - size = size.expandedTo(EntityGUI_Dir1_QTD->minimumSizeHint()); - EntityGUI_Dir1_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_Dir1_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_Dir1_QTD) - { - EntityGUI_Dir1_QTD->setWindowTitle(QApplication::translate("EntityGUI_Dir1_QTD", "EntityGUI_Dir1_QTD", 0, QApplication::UnicodeUTF8)); - GroupDir1->setTitle(QApplication::translate("EntityGUI_Dir1_QTD", "Direction", 0, QApplication::UnicodeUTF8)); - RB_Dir12->setText(QApplication::translate("EntityGUI_Dir1_QTD", "Perpendicular", 0, QApplication::UnicodeUTF8)); - RB_Dir13->setText(QApplication::translate("EntityGUI_Dir1_QTD", "Tangent", 0, QApplication::UnicodeUTF8)); - RB_Dir11->setText(QApplication::translate("EntityGUI_Dir1_QTD", "Angle", 0, QApplication::UnicodeUTF8)); - RB_Dir14->setText(QApplication::translate("EntityGUI_Dir1_QTD", "VX-VY", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_Dir1_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_Dir1_QTD: public Ui_EntityGUI_Dir1_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_DIR1_QTD_H diff --git a/src/EntityGUI/EntityGUI_Dir1_QTD.ui b/src/EntityGUI/EntityGUI_Dir1_QTD.ui new file mode 100644 index 000000000..009fbaf1a --- /dev/null +++ b/src/EntityGUI/EntityGUI_Dir1_QTD.ui @@ -0,0 +1,85 @@ + + EntityGUI_Dir1_QTD + + + + 0 + 0 + 120 + 124 + + + + EntityGUI_Dir1_QTD + + + + 0 + + + 0 + + + + + + 7 + 0 + 0 + 0 + + + + Direction + + + + 9 + + + 6 + + + + + VX-VY + + + + + + + Tangent + + + + + + + Angle + + + + + + + Perpendicular + + + + + + + + + + qPixmapFromMimeSource + + RB_Dir11 + RB_Dir12 + RB_Dir13 + RB_Dir14 + + + + diff --git a/src/EntityGUI/EntityGUI_Dir2_QTD.h b/src/EntityGUI/EntityGUI_Dir2_QTD.h deleted file mode 100644 index 5cffa22f8..000000000 --- a/src/EntityGUI/EntityGUI_Dir2_QTD.h +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_Dir2_QTD.ui' -** -** Created: Tue Jul 10 10:24:41 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_DIR2_QTD_H -#define ENTITYGUI_DIR2_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_Dir2_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupDir2; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QRadioButton *RB_Dir22; - QRadioButton *RB_Dir23; - QSpacerItem *spacerItem; - QRadioButton *RB_Dir21; - - void setupUi(QWidget *EntityGUI_Dir2_QTD) - { - EntityGUI_Dir2_QTD->setObjectName(QString::fromUtf8("EntityGUI_Dir2_QTD")); - gridLayout = new QGridLayout(EntityGUI_Dir2_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupDir2 = new QGroupBox(EntityGUI_Dir2_QTD); - GroupDir2->setObjectName(QString::fromUtf8("GroupDir2")); - QSizePolicy sizePolicy(static_cast(7), static_cast(7)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(GroupDir2->sizePolicy().hasHeightForWidth()); - GroupDir2->setSizePolicy(sizePolicy); - gridLayout1 = new QGridLayout(GroupDir2); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - RB_Dir22 = new QRadioButton(GroupDir2); - RB_Dir22->setObjectName(QString::fromUtf8("RB_Dir22")); - - gridLayout2->addWidget(RB_Dir22, 1, 0, 1, 1); - - RB_Dir23 = new QRadioButton(GroupDir2); - RB_Dir23->setObjectName(QString::fromUtf8("RB_Dir23")); - - gridLayout2->addWidget(RB_Dir23, 2, 0, 1, 1); - - spacerItem = new QSpacerItem(0, 20, QSizePolicy::Minimum, QSizePolicy::Expanding); - - gridLayout2->addItem(spacerItem, 3, 0, 1, 1); - - RB_Dir21 = new QRadioButton(GroupDir2); - RB_Dir21->setObjectName(QString::fromUtf8("RB_Dir21")); - - gridLayout2->addWidget(RB_Dir21, 0, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupDir2, 0, 0, 1, 1); - - QWidget::setTabOrder(RB_Dir21, RB_Dir22); - QWidget::setTabOrder(RB_Dir22, RB_Dir23); - - retranslateUi(EntityGUI_Dir2_QTD); - - QSize size(124, 106); - size = size.expandedTo(EntityGUI_Dir2_QTD->minimumSizeHint()); - EntityGUI_Dir2_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_Dir2_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_Dir2_QTD) - { - EntityGUI_Dir2_QTD->setWindowTitle(QApplication::translate("EntityGUI_Dir2_QTD", "EntityGUI_Dir2_QTD", 0, QApplication::UnicodeUTF8)); - GroupDir2->setTitle(QApplication::translate("EntityGUI_Dir2_QTD", "Direction", 0, QApplication::UnicodeUTF8)); - RB_Dir22->setText(QApplication::translate("EntityGUI_Dir2_QTD", "X", 0, QApplication::UnicodeUTF8)); - RB_Dir23->setText(QApplication::translate("EntityGUI_Dir2_QTD", "Y", 0, QApplication::UnicodeUTF8)); - RB_Dir21->setText(QApplication::translate("EntityGUI_Dir2_QTD", "Length", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_Dir2_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_Dir2_QTD: public Ui_EntityGUI_Dir2_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_DIR2_QTD_H diff --git a/src/EntityGUI/EntityGUI_Dir2_QTD.ui b/src/EntityGUI/EntityGUI_Dir2_QTD.ui new file mode 100644 index 000000000..67d7398ee --- /dev/null +++ b/src/EntityGUI/EntityGUI_Dir2_QTD.ui @@ -0,0 +1,77 @@ + + EntityGUI_Dir2_QTD + + + + 0 + 0 + 91 + 100 + + + + EntityGUI_Dir2_QTD + + + + 0 + + + 6 + + + + + + 7 + 7 + 0 + 0 + + + + Direction + + + + 9 + + + 6 + + + + + Length + + + + + + + Y + + + + + + + X + + + + + + + + + + qPixmapFromMimeSource + + RB_Dir21 + RB_Dir22 + RB_Dir23 + + + + diff --git a/src/EntityGUI/EntityGUI_Point_QTD.h b/src/EntityGUI/EntityGUI_Point_QTD.h deleted file mode 100644 index 897833f5e..000000000 --- a/src/EntityGUI/EntityGUI_Point_QTD.h +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_Point_QTD.ui' -** -** Created: Mon Jul 9 17:24:53 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_POINT_QTD_H -#define ENTITYGUI_POINT_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_Point_QTD -{ -public: - QGridLayout *gridLayout; - QGroupBox *GroupPoint; - QGridLayout *gridLayout1; - QGridLayout *gridLayout2; - QRadioButton *RB_Point2; - QRadioButton *RB_Point1; - QRadioButton *RB_Point3; - - void setupUi(QWidget *EntityGUI_Point_QTD) - { - EntityGUI_Point_QTD->setObjectName(QString::fromUtf8("EntityGUI_Point_QTD")); - gridLayout = new QGridLayout(EntityGUI_Point_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(0); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - GroupPoint = new QGroupBox(EntityGUI_Point_QTD); - GroupPoint->setObjectName(QString::fromUtf8("GroupPoint")); - QSizePolicy sizePolicy(static_cast(7), static_cast(0)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(GroupPoint->sizePolicy().hasHeightForWidth()); - GroupPoint->setSizePolicy(sizePolicy); - gridLayout1 = new QGridLayout(GroupPoint); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(11); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - gridLayout2 = new QGridLayout(); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(0); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - RB_Point2 = new QRadioButton(GroupPoint); - RB_Point2->setObjectName(QString::fromUtf8("RB_Point2")); - - gridLayout2->addWidget(RB_Point2, 1, 0, 1, 1); - - RB_Point1 = new QRadioButton(GroupPoint); - RB_Point1->setObjectName(QString::fromUtf8("RB_Point1")); - - gridLayout2->addWidget(RB_Point1, 0, 0, 1, 1); - - RB_Point3 = new QRadioButton(GroupPoint); - RB_Point3->setObjectName(QString::fromUtf8("RB_Point3")); - - gridLayout2->addWidget(RB_Point3, 2, 0, 1, 1); - - - gridLayout1->addLayout(gridLayout2, 0, 0, 1, 1); - - - gridLayout->addWidget(GroupPoint, 0, 0, 1, 1); - - QWidget::setTabOrder(RB_Point1, RB_Point2); - QWidget::setTabOrder(RB_Point2, RB_Point3); - - retranslateUi(EntityGUI_Point_QTD); - - QSize size(124, 106); - size = size.expandedTo(EntityGUI_Point_QTD->minimumSizeHint()); - EntityGUI_Point_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_Point_QTD); - } // setupUi - - void retranslateUi(QWidget *EntityGUI_Point_QTD) - { - EntityGUI_Point_QTD->setWindowTitle(QApplication::translate("EntityGUI_Point_QTD", "EntityGUI_Point_QTD", 0, QApplication::UnicodeUTF8)); - GroupPoint->setTitle(QApplication::translate("EntityGUI_Point_QTD", "Point", 0, QApplication::UnicodeUTF8)); - RB_Point2->setText(QApplication::translate("EntityGUI_Point_QTD", "Relative", 0, QApplication::UnicodeUTF8)); - RB_Point1->setText(QApplication::translate("EntityGUI_Point_QTD", "Absolute", 0, QApplication::UnicodeUTF8)); - RB_Point3->setText(QApplication::translate("EntityGUI_Point_QTD", "Selection", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_Point_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_Point_QTD: public Ui_EntityGUI_Point_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_POINT_QTD_H diff --git a/src/EntityGUI/EntityGUI_Point_QTD.ui b/src/EntityGUI/EntityGUI_Point_QTD.ui new file mode 100644 index 000000000..a0bc2d6c9 --- /dev/null +++ b/src/EntityGUI/EntityGUI_Point_QTD.ui @@ -0,0 +1,77 @@ + + EntityGUI_Point_QTD + + + + 0 + 0 + 97 + 100 + + + + EntityGUI_Point_QTD + + + + 0 + + + 0 + + + + + + 7 + 0 + 0 + 0 + + + + Point + + + + 9 + + + 6 + + + + + Relative + + + + + + + Selection + + + + + + + Absolute + + + + + + + + + + qPixmapFromMimeSource + + RB_Point1 + RB_Point2 + RB_Point3 + + + + diff --git a/src/EntityGUI/EntityGUI_Skeleton_QTD.h b/src/EntityGUI/EntityGUI_Skeleton_QTD.h deleted file mode 100644 index ee39349c4..000000000 --- a/src/EntityGUI/EntityGUI_Skeleton_QTD.h +++ /dev/null @@ -1,287 +0,0 @@ -/******************************************************************************** -** Form generated from reading ui file 'EntityGUI_Skeleton_QTD.ui' -** -** Created: Mon Jul 9 17:21:08 2007 -** by: Qt User Interface Compiler version 4.2.3 -** -** WARNING! All changes made in this file will be lost when recompiling ui file! -********************************************************************************/ - -#ifndef ENTITYGUI_SKELETON_QTD_H -#define ENTITYGUI_SKELETON_QTD_H - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -class Ui_EntityGUI_Skeleton_QTD -{ -public: - QGridLayout *gridLayout; - QGridLayout *gridLayout1; - QGroupBox *GroupVal; - QGroupBox *GroupConstructors; - QGridLayout *gridLayout2; - QHBoxLayout *hboxLayout; - QRadioButton *RadioButton1; - QRadioButton *RadioButton2; - QGroupBox *GroupDest; - QGridLayout *gridLayout3; - QGridLayout *gridLayout4; - QGroupBox *GroupDest1; - QGridLayout *gridLayout5; - QGridLayout *gridLayout6; - QRadioButton *RB_Dest2; - QRadioButton *RB_Dest1; - QGroupBox *GroupDest2; - QGridLayout *gridLayout7; - QGroupBox *GroupDest3; - QGridLayout *gridLayout8; - QGroupBox *GroupButtons; - QHBoxLayout *hboxLayout1; - QHBoxLayout *hboxLayout2; - QPushButton *buttonEnd; - QPushButton *buttonClose; - QSpacerItem *spacerItem; - QPushButton *buttonCancel; - QPushButton *buttonHelp; - - void setupUi(QDialog *EntityGUI_Skeleton_QTD) - { - EntityGUI_Skeleton_QTD->setObjectName(QString::fromUtf8("EntityGUI_Skeleton_QTD")); - QSizePolicy sizePolicy(static_cast(5), static_cast(7)); - sizePolicy.setHorizontalStretch(0); - sizePolicy.setVerticalStretch(0); - sizePolicy.setHeightForWidth(EntityGUI_Skeleton_QTD->sizePolicy().hasHeightForWidth()); - EntityGUI_Skeleton_QTD->setSizePolicy(sizePolicy); - gridLayout = new QGridLayout(EntityGUI_Skeleton_QTD); - gridLayout->setSpacing(6); - gridLayout->setMargin(11); - gridLayout->setObjectName(QString::fromUtf8("gridLayout")); - gridLayout1 = new QGridLayout(); - gridLayout1->setSpacing(6); - gridLayout1->setMargin(0); - gridLayout1->setObjectName(QString::fromUtf8("gridLayout1")); - GroupVal = new QGroupBox(EntityGUI_Skeleton_QTD); - GroupVal->setObjectName(QString::fromUtf8("GroupVal")); - QSizePolicy sizePolicy1(static_cast(7), static_cast(7)); - sizePolicy1.setHorizontalStretch(0); - sizePolicy1.setVerticalStretch(0); - sizePolicy1.setHeightForWidth(GroupVal->sizePolicy().hasHeightForWidth()); - GroupVal->setSizePolicy(sizePolicy1); - - gridLayout1->addWidget(GroupVal, 2, 0, 1, 1); - - GroupConstructors = new QGroupBox(EntityGUI_Skeleton_QTD); - GroupConstructors->setObjectName(QString::fromUtf8("GroupConstructors")); - QSizePolicy sizePolicy2(static_cast(5), static_cast(0)); - sizePolicy2.setHorizontalStretch(0); - sizePolicy2.setVerticalStretch(0); - sizePolicy2.setHeightForWidth(GroupConstructors->sizePolicy().hasHeightForWidth()); - GroupConstructors->setSizePolicy(sizePolicy2); - gridLayout2 = new QGridLayout(GroupConstructors); - gridLayout2->setSpacing(6); - gridLayout2->setMargin(11); - gridLayout2->setObjectName(QString::fromUtf8("gridLayout2")); - hboxLayout = new QHBoxLayout(); - hboxLayout->setSpacing(6); - hboxLayout->setMargin(0); - hboxLayout->setObjectName(QString::fromUtf8("hboxLayout")); - RadioButton1 = new QRadioButton(GroupConstructors); - RadioButton1->setObjectName(QString::fromUtf8("RadioButton1")); - - hboxLayout->addWidget(RadioButton1); - - RadioButton2 = new QRadioButton(GroupConstructors); - RadioButton2->setObjectName(QString::fromUtf8("RadioButton2")); - - hboxLayout->addWidget(RadioButton2); - - - gridLayout2->addLayout(hboxLayout, 0, 0, 1, 1); - - - gridLayout1->addWidget(GroupConstructors, 0, 0, 1, 1); - - GroupDest = new QGroupBox(EntityGUI_Skeleton_QTD); - GroupDest->setObjectName(QString::fromUtf8("GroupDest")); - QSizePolicy sizePolicy3(static_cast(7), static_cast(0)); - sizePolicy3.setHorizontalStretch(0); - sizePolicy3.setVerticalStretch(0); - sizePolicy3.setHeightForWidth(GroupDest->sizePolicy().hasHeightForWidth()); - GroupDest->setSizePolicy(sizePolicy3); - gridLayout3 = new QGridLayout(GroupDest); - gridLayout3->setSpacing(6); - gridLayout3->setMargin(11); - gridLayout3->setObjectName(QString::fromUtf8("gridLayout3")); - gridLayout4 = new QGridLayout(); - gridLayout4->setSpacing(6); - gridLayout4->setMargin(0); - gridLayout4->setObjectName(QString::fromUtf8("gridLayout4")); - GroupDest1 = new QGroupBox(GroupDest); - GroupDest1->setObjectName(QString::fromUtf8("GroupDest1")); - QSizePolicy sizePolicy4(static_cast(7), static_cast(0)); - sizePolicy4.setHorizontalStretch(0); - sizePolicy4.setVerticalStretch(0); - sizePolicy4.setHeightForWidth(GroupDest1->sizePolicy().hasHeightForWidth()); - GroupDest1->setSizePolicy(sizePolicy4); - gridLayout5 = new QGridLayout(GroupDest1); - gridLayout5->setSpacing(6); - gridLayout5->setMargin(11); - gridLayout5->setObjectName(QString::fromUtf8("gridLayout5")); - gridLayout6 = new QGridLayout(); - gridLayout6->setSpacing(6); - gridLayout6->setMargin(0); - gridLayout6->setObjectName(QString::fromUtf8("gridLayout6")); - RB_Dest2 = new QRadioButton(GroupDest1); - RB_Dest2->setObjectName(QString::fromUtf8("RB_Dest2")); - - gridLayout6->addWidget(RB_Dest2, 0, 1, 1, 1); - - RB_Dest1 = new QRadioButton(GroupDest1); - RB_Dest1->setObjectName(QString::fromUtf8("RB_Dest1")); - - gridLayout6->addWidget(RB_Dest1, 0, 0, 1, 1); - - - gridLayout5->addLayout(gridLayout6, 0, 0, 1, 1); - - - gridLayout4->addWidget(GroupDest1, 0, 0, 1, 2); - - GroupDest2 = new QGroupBox(GroupDest); - GroupDest2->setObjectName(QString::fromUtf8("GroupDest2")); - QSizePolicy sizePolicy5(static_cast(7), static_cast(7)); - sizePolicy5.setHorizontalStretch(0); - sizePolicy5.setVerticalStretch(0); - sizePolicy5.setHeightForWidth(GroupDest2->sizePolicy().hasHeightForWidth()); - GroupDest2->setSizePolicy(sizePolicy5); - gridLayout7 = new QGridLayout(GroupDest2); - gridLayout7->setSpacing(6); - gridLayout7->setMargin(11); - gridLayout7->setObjectName(QString::fromUtf8("gridLayout7")); - - gridLayout4->addWidget(GroupDest2, 1, 0, 1, 1); - - GroupDest3 = new QGroupBox(GroupDest); - GroupDest3->setObjectName(QString::fromUtf8("GroupDest3")); - QSizePolicy sizePolicy6(static_cast(7), static_cast(7)); - sizePolicy6.setHorizontalStretch(0); - sizePolicy6.setVerticalStretch(0); - sizePolicy6.setHeightForWidth(GroupDest3->sizePolicy().hasHeightForWidth()); - GroupDest3->setSizePolicy(sizePolicy6); - gridLayout8 = new QGridLayout(GroupDest3); - gridLayout8->setSpacing(6); - gridLayout8->setMargin(11); - gridLayout8->setObjectName(QString::fromUtf8("gridLayout8")); - - gridLayout4->addWidget(GroupDest3, 1, 1, 1, 1); - - - gridLayout3->addLayout(gridLayout4, 0, 0, 1, 1); - - - gridLayout1->addWidget(GroupDest, 1, 0, 1, 1); - - GroupButtons = new QGroupBox(EntityGUI_Skeleton_QTD); - GroupButtons->setObjectName(QString::fromUtf8("GroupButtons")); - QSizePolicy sizePolicy7(static_cast(7), static_cast(0)); - sizePolicy7.setHorizontalStretch(0); - sizePolicy7.setVerticalStretch(0); - sizePolicy7.setHeightForWidth(GroupButtons->sizePolicy().hasHeightForWidth()); - GroupButtons->setSizePolicy(sizePolicy7); - hboxLayout1 = new QHBoxLayout(GroupButtons); - hboxLayout1->setSpacing(6); - hboxLayout1->setMargin(11); - hboxLayout1->setObjectName(QString::fromUtf8("hboxLayout1")); - hboxLayout2 = new QHBoxLayout(); - hboxLayout2->setSpacing(6); - hboxLayout2->setMargin(0); - hboxLayout2->setObjectName(QString::fromUtf8("hboxLayout2")); - buttonEnd = new QPushButton(GroupButtons); - buttonEnd->setObjectName(QString::fromUtf8("buttonEnd")); - - hboxLayout2->addWidget(buttonEnd); - - buttonClose = new QPushButton(GroupButtons); - buttonClose->setObjectName(QString::fromUtf8("buttonClose")); - - hboxLayout2->addWidget(buttonClose); - - spacerItem = new QSpacerItem(91, 0, QSizePolicy::Expanding, QSizePolicy::Minimum); - - hboxLayout2->addItem(spacerItem); - - buttonCancel = new QPushButton(GroupButtons); - buttonCancel->setObjectName(QString::fromUtf8("buttonCancel")); - - hboxLayout2->addWidget(buttonCancel); - - buttonHelp = new QPushButton(GroupButtons); - buttonHelp->setObjectName(QString::fromUtf8("buttonHelp")); - - hboxLayout2->addWidget(buttonHelp); - - - hboxLayout1->addLayout(hboxLayout2); - - - gridLayout1->addWidget(GroupButtons, 3, 0, 1, 1); - - - gridLayout->addLayout(gridLayout1, 0, 0, 1, 1); - - QWidget::setTabOrder(RadioButton1, RadioButton2); - QWidget::setTabOrder(RadioButton2, RB_Dest1); - QWidget::setTabOrder(RB_Dest1, RB_Dest2); - QWidget::setTabOrder(RB_Dest2, buttonEnd); - QWidget::setTabOrder(buttonEnd, buttonClose); - QWidget::setTabOrder(buttonClose, buttonCancel); - - retranslateUi(EntityGUI_Skeleton_QTD); - - QSize size(317, 276); - size = size.expandedTo(EntityGUI_Skeleton_QTD->minimumSizeHint()); - EntityGUI_Skeleton_QTD->resize(size); - - - QMetaObject::connectSlotsByName(EntityGUI_Skeleton_QTD); - } // setupUi - - void retranslateUi(QDialog *EntityGUI_Skeleton_QTD) - { - EntityGUI_Skeleton_QTD->setWindowTitle(QApplication::translate("EntityGUI_Skeleton_QTD", "EntityGUI_Skeleton_QTD", 0, QApplication::UnicodeUTF8)); - GroupVal->setTitle(QString()); - GroupConstructors->setTitle(QApplication::translate("EntityGUI_Skeleton_QTD", "Element Type", 0, QApplication::UnicodeUTF8)); - RadioButton1->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "Segment", 0, QApplication::UnicodeUTF8)); - RadioButton2->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "Arc", 0, QApplication::UnicodeUTF8)); - GroupDest->setTitle(QApplication::translate("EntityGUI_Skeleton_QTD", "Destination", 0, QApplication::UnicodeUTF8)); - GroupDest1->setTitle(QApplication::translate("EntityGUI_Skeleton_QTD", "Type", 0, QApplication::UnicodeUTF8)); - RB_Dest2->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "Direction", 0, QApplication::UnicodeUTF8)); - RB_Dest1->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "Point", 0, QApplication::UnicodeUTF8)); - GroupDest2->setTitle(QString()); - GroupDest3->setTitle(QString()); - GroupButtons->setTitle(QString()); - buttonEnd->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "End Sketch", 0, QApplication::UnicodeUTF8)); - buttonClose->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "Close Sketch", 0, QApplication::UnicodeUTF8)); - buttonCancel->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "&Cancel", 0, QApplication::UnicodeUTF8)); - buttonHelp->setText(QApplication::translate("EntityGUI_Skeleton_QTD", "&Help", 0, QApplication::UnicodeUTF8)); - Q_UNUSED(EntityGUI_Skeleton_QTD); - } // retranslateUi - -}; - -namespace Ui { - class EntityGUI_Skeleton_QTD: public Ui_EntityGUI_Skeleton_QTD {}; -} // namespace Ui - -#endif // ENTITYGUI_SKELETON_QTD_H diff --git a/src/EntityGUI/EntityGUI_Skeleton_QTD.ui b/src/EntityGUI/EntityGUI_Skeleton_QTD.ui new file mode 100644 index 000000000..188f5edd8 --- /dev/null +++ b/src/EntityGUI/EntityGUI_Skeleton_QTD.ui @@ -0,0 +1,206 @@ + + EntityGUI_Skeleton_QTD + + + + 0 + 0 + 362 + 207 + + + + Form + + + + 0 + + + 6 + + + + + + 7 + 0 + 0 + 0 + + + + + + + + 9 + + + 6 + + + + + End Sketch + + + + + + + Close Sketch + + + + + + + Qt::Horizontal + + + QSizePolicy::Expanding + + + + 91 + 0 + + + + + + + + &Cancel + + + + + + + &Help + + + + + + + + + + + + + + 7 + 0 + 0 + 0 + + + + Destination + + + + 9 + + + 6 + + + + + + + + + 7 + 0 + 0 + 0 + + + + Type + + + + 9 + + + 6 + + + + + Point + + + + + + + Direction + + + + + + + + + + + + + + 5 + 0 + 0 + 0 + + + + Element Type + + + + 9 + + + 6 + + + + + Segment + + + + + + + Arc + + + + + + + + + + RadioButton1 + RadioButton2 + RB_Dest1 + RB_Dest2 + buttonEnd + buttonClose + buttonCancel + buttonHelp + + + + diff --git a/src/EntityGUI/EntityGUI_SketcherDlg.cxx b/src/EntityGUI/EntityGUI_SketcherDlg.cxx index b9f1a82e6..916cf0f54 100644 --- a/src/EntityGUI/EntityGUI_SketcherDlg.cxx +++ b/src/EntityGUI/EntityGUI_SketcherDlg.cxx @@ -1,51 +1,42 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI_SketcherDlg.cxx +// Author : Damien COQUERET, Open CASCADE S.A.S. // -// -// File : EntityGUI_SketcherDlg.cxx -// Author : Damien COQUERET -// Module : GEOM -// $Header$ #include "EntityGUI_SketcherDlg.h" -#include "Sketcher_Profile.hxx" -#include "GEOMBase.h" - -#include "EntityGUI_1Spin.h" -#include "EntityGUI_2Spin.h" -#include "EntityGUI_3Spin.h" -#include "EntityGUI_4Spin.h" - -#include "DlgRef_SpinBox.h" +#include "EntityGUI_Widgets.h" -#include "GeometryGUI.h" +#include +#include +#include -#include "SUIT_Desktop.h" -#include "SUIT_Session.h" -#include "SUIT_MessageBox.h" -#include "SUIT_ResourceMgr.h" -#include "SalomeApp_Application.h" -#include "LightApp_Application.h" -#include "LightApp_SelectionMgr.h" +#include +#include +#include +#include +#include +#include +#include #include @@ -56,10 +47,7 @@ #include #include #include - -#include "GEOMImpl_Types.hxx" - -using namespace std; +#include //================================================================================= // class : EntityGUI_SketcherDlg() @@ -68,218 +56,198 @@ using namespace std; // The dialog will by default be modeless, unless you set 'modal' to // TRUE to construct a modal dialog. //================================================================================= -EntityGUI_SketcherDlg::EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent, - const char* name, bool modal, Qt::WindowFlags fl, - const double lineWidth) - :QDialog(parent, Qt::WindowTitleHint | Qt::WindowSystemMenuHint), - myIsAllAdded( false ), - GEOMBase_Helper( dynamic_cast( parent ) ), - myGeometryGUI( GUI ), - myLineWidth( lineWidth ) +EntityGUI_SketcherDlg::EntityGUI_SketcherDlg( GeometryGUI* GUI, QWidget* parent, + bool modal, Qt::WindowFlags fl, + const double lineWidth ) + : QDialog( parent, fl ), + myIsAllAdded( false ), + GEOMBase_Helper( dynamic_cast( parent ) ), + myGeometryGUI( GUI ), + myLineWidth( lineWidth ) { - setupUi(this); - setModal( modal ); setAttribute( Qt::WA_DeleteOnClose ); myGeometryGUI->SetActiveDialogBox(this); - if ( !name ) - setObjectName("EntityGUI_SketcherDlg"); - else - setObjectName(name); - - buttonCancel->setText(tr("GEOM_BUT_CANCEL")); - buttonEnd->setText(tr("GEOM_BUT_END_SKETCH")); - buttonClose->setText(tr("GEOM_BUT_CLOSE_SKETCH")); - buttonHelp->setText(tr("GEOM_BUT_HELP")); - - GroupVal->setAttribute( Qt::WA_DeleteOnClose ); - GroupVal->close(); - GroupDest2->setAttribute( Qt::WA_DeleteOnClose ); - GroupDest2->close(); - GroupDest3->setAttribute( Qt::WA_DeleteOnClose ); - GroupDest3->close(); - - QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT"))); - QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_UNDO"))); - QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_REDO"))); - - setWindowTitle(tr("GEOM_SKETCHER_TITLE")); - - GroupConstructors->setTitle(tr("GEOM_SKETCHER_EL")); - RadioButton1->setText(tr("GEOM_SKETCHER_SEGMENT")); - RadioButton2->setText(tr("GEOM_SKETCHER_ARC")); - GroupDest->setTitle(tr("GEOM_SKETCHER_DEST")); - GroupDest1->setTitle(tr("GEOM_SKETCHER_TYPE")); - RB_Dest1->setText(tr("GEOM_SKETCHER_POINT")); - RB_Dest2->setText(tr("GEOM_SKETCHER_DIR")); + MainWidget = new EntityGUI_Skeleton( this ); + QVBoxLayout* topLayout = new QVBoxLayout( this ); + topLayout->setMargin( 9 ); topLayout->setSpacing( 6 ); + topLayout->addWidget( MainWidget ); + + MainWidget->buttonCancel->setText( tr( "GEOM_BUT_CANCEL" ) ); + MainWidget->buttonEnd->setText( tr( "GEOM_BUT_END_SKETCH" ) ); + MainWidget->buttonClose->setText( tr( "GEOM_BUT_CLOSE_SKETCH" ) ); + MainWidget->buttonHelp->setText( tr( "GEOM_BUT_HELP" ) ); + + QPixmap image0( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) ); + QPixmap image1( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_UNDO" ) ) ); + QPixmap image2( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_REDO" ) ) ); + + setWindowTitle( tr( "GEOM_SKETCHER_TITLE" ) ); + + MainWidget->GroupConstructors->setTitle( tr( "GEOM_SKETCHER_EL" ) ); + MainWidget->RadioButton1->setText( tr( "GEOM_SKETCHER_SEGMENT" ) ); + MainWidget->RadioButton2->setText( tr( "GEOM_SKETCHER_ARC" ) ); + MainWidget->GroupDest->setTitle( tr( "GEOM_SKETCHER_DEST" ) ); + MainWidget->GroupDest1->setTitle( tr( "GEOM_SKETCHER_TYPE" ) ); + MainWidget->RB_Dest1->setText( tr( "GEOM_SKETCHER_POINT" ) ); + MainWidget->RB_Dest2->setText( tr( "GEOM_SKETCHER_DIR" ) ); /***************************************************************/ - GroupPt = new Ui::EntityGUI_Point_QTD(); - QWidget* aGroupPtWidget = new QWidget(GroupDest); - GroupPt->setupUi(aGroupPtWidget); - aGroupPtWidget->setObjectName("GroupPt"); - - GroupPt->GroupPoint->setTitle(tr("GEOM_SKETCHER_POINT")); - GroupPt->RB_Point1->setText(tr("GEOM_SKETCHER_ABS")); - GroupPt->RB_Point2->setText(tr("GEOM_SKETCHER_REL")); - GroupPt->RB_Point3->setText(tr("GEOM_SKETCHER_SEL")); - - GroupD1 = new Ui::EntityGUI_Dir1_QTD(); - QWidget* aGroupD1Widget = new QWidget(GroupDest); - GroupD1->setupUi(aGroupD1Widget); - aGroupD1Widget->setObjectName("GroupD1"); - - GroupD1->GroupDir1->setTitle(tr("GEOM_SKETCHER_DIR")); - GroupD1->RB_Dir11->setText(tr("GEOM_SKETCHER_ANGLE")); - GroupD1->RB_Dir12->setText(tr("GEOM_SKETCHER_PER")); - GroupD1->RB_Dir13->setText(tr("GEOM_SKETCHER_TAN")); - GroupD1->RB_Dir14->setText(tr("GEOM_SKETCHER_VXVY")); - - GroupD2 = new Ui::EntityGUI_Dir2_QTD(); - QWidget* aGroupD2Widget = new QWidget(GroupDest); - GroupD2->setupUi(aGroupD2Widget); - aGroupD2Widget->setObjectName("GroupD2"); - - GroupD2->GroupDir2->setTitle(tr("GEOM_SKETCHER_DIR")); - GroupD2->RB_Dir21->setText(tr("GEOM_SKETCHER_LENGTH")); - GroupD2->RB_Dir22->setText(tr("GEOM_SKETCHER_X")); - GroupD2->RB_Dir23->setText(tr("GEOM_SKETCHER_Y")); - - Group1Sel = new Ui::EntityGUI_1Sel_QTD(); - QWidget* aGroup1SelWidget = new QWidget(this); - Group1Sel->setupUi(aGroup1SelWidget); - aGroup1SelWidget->setObjectName("Group1Sel"); - - Group1Sel->TextLabel1->setText(tr("GEOM_SKETCHER_POINT2")); - Group1Sel->GroupBox1->setTitle(tr("GEOM_SKETCHER_VALUES")); - Group1Sel->buttonApply->setText(tr("GEOM_SKETCHER_APPLY")); - Group1Sel->PushButton1->setIcon(image0); - Group1Sel->buttonUndo->setIcon(image1); - Group1Sel->buttonRedo->setIcon(image2); + GroupPt = new EntityGUI_Point( MainWidget->DestCnt ); + + GroupPt->GroupPoint->setTitle( tr( "GEOM_SKETCHER_POINT" ) ); + GroupPt->RB_Point1->setText( tr( "GEOM_SKETCHER_ABS" ) ); + GroupPt->RB_Point2->setText( tr( "GEOM_SKETCHER_REL" ) ); + GroupPt->RB_Point3->setText( tr( "GEOM_SKETCHER_SEL" ) ); + + GroupD1 = new EntityGUI_Dir1( MainWidget->DestCnt ); + + GroupD1->GroupDir1->setTitle( tr( "GEOM_SKETCHER_DIR" ) ); + GroupD1->RB_Dir11->setText( tr( "GEOM_SKETCHER_ANGLE" ) ); + GroupD1->RB_Dir12->setText( tr( "GEOM_SKETCHER_PER" ) ); + GroupD1->RB_Dir13->setText( tr( "GEOM_SKETCHER_TAN" ) ); + GroupD1->RB_Dir14->setText( tr( "GEOM_SKETCHER_VXVY" ) ); + + GroupD2 = new EntityGUI_Dir2( MainWidget->DestCnt ); + + GroupD2->GroupDir2->setTitle( tr( "GEOM_SKETCHER_DIR" ) ); + GroupD2->RB_Dir21->setText( tr( "GEOM_SKETCHER_LENGTH" ) ); + GroupD2->RB_Dir22->setText( tr( "GEOM_SKETCHER_X" ) ); + GroupD2->RB_Dir23->setText( tr( "GEOM_SKETCHER_Y" ) ); + + Group1Sel = new EntityGUI_1Sel( MainWidget->SkeletonCnt ); + + Group1Sel->TextLabel1->setText( tr( "GEOM_SKETCHER_POINT2" ) ); + Group1Sel->GroupBox1->setTitle( tr( "GEOM_SKETCHER_VALUES" ) ); + Group1Sel->buttonApply->setText( tr( "GEOM_SKETCHER_APPLY" ) ); + Group1Sel->PushButton1->setIcon( image0 ); + Group1Sel->buttonUndo->setIcon( image1 ); + Group1Sel->buttonRedo->setIcon( image2 ); Group1Sel->LineEdit1->setReadOnly( true ); - Group1Spin = new EntityGUI_1Spin(this, "Group1Spin"); - Group1Spin->GroupBox1->setTitle(tr("GEOM_SKETCHER_VALUES")); - Group1Spin->buttonApply->setText(tr("GEOM_SKETCHER_APPLY")); - Group1Spin->buttonUndo->setIcon(image1); - Group1Spin->buttonRedo->setIcon(image2); - QWidget::setTabOrder(Group1Spin->SpinBox_DX , Group1Spin->buttonApply); - QWidget::setTabOrder(Group1Spin->buttonApply, Group1Spin->buttonUndo); - QWidget::setTabOrder(Group1Spin->buttonUndo , Group1Spin->buttonRedo); - - Group2Spin = new EntityGUI_2Spin(this, "Group2Spin"); - Group2Spin->GroupBox1->setTitle(tr("GEOM_SKETCHER_VALUES")); - Group2Spin->buttonApply->setText(tr("GEOM_SKETCHER_APPLY")); - Group2Spin->buttonUndo->setIcon(image1); - Group2Spin->buttonRedo->setIcon(image2); - QWidget::setTabOrder(Group2Spin->SpinBox_DX , Group2Spin->SpinBox_DY); - QWidget::setTabOrder(Group2Spin->SpinBox_DY , Group2Spin->buttonApply); - QWidget::setTabOrder(Group2Spin->buttonApply, Group2Spin->buttonUndo); - QWidget::setTabOrder(Group2Spin->buttonUndo , Group2Spin->buttonRedo); - - Group3Spin = new EntityGUI_3Spin(this, "Group3Spin"); - Group3Spin->GroupBox1->setTitle(tr("GEOM_SKETCHER_VALUES")); - Group3Spin->buttonApply->setText(tr("GEOM_SKETCHER_APPLY")); - Group3Spin->buttonUndo->setIcon(image1); - Group3Spin->buttonRedo->setIcon(image2); - QWidget::setTabOrder(Group3Spin->SpinBox_DX , Group3Spin->SpinBox_DY); - QWidget::setTabOrder(Group3Spin->SpinBox_DY , Group3Spin->SpinBox_DZ); - QWidget::setTabOrder(Group3Spin->SpinBox_DZ , Group3Spin->buttonApply); - QWidget::setTabOrder(Group3Spin->buttonApply, Group3Spin->buttonUndo); - QWidget::setTabOrder(Group3Spin->buttonUndo , Group3Spin->buttonRedo); - - Group4Spin = new EntityGUI_4Spin(this, "Group4Spin"); - Group4Spin->GroupBox1->setTitle(tr("GEOM_SKETCHER_VALUES")); - Group4Spin->buttonApply->setText(tr("GEOM_SKETCHER_APPLY")); - Group4Spin->buttonUndo->setIcon(image1); - Group4Spin->buttonRedo->setIcon(image2); - QWidget::setTabOrder(Group4Spin->SpinBox_DX , Group4Spin->SpinBox_DY); - QWidget::setTabOrder(Group4Spin->SpinBox_DY , Group4Spin->SpinBox_DZ); - QWidget::setTabOrder(Group4Spin->SpinBox_DZ , Group4Spin->SpinBox_DS); - QWidget::setTabOrder(Group4Spin->SpinBox_DS , Group4Spin->buttonApply); - QWidget::setTabOrder(Group4Spin->buttonApply, Group4Spin->buttonUndo); - QWidget::setTabOrder(Group4Spin->buttonUndo , Group4Spin->buttonRedo); - - gridLayout4->addWidget(aGroupPtWidget, 1, 0, 1, 2); - gridLayout4->addWidget(aGroupD1Widget, 1, 0); - gridLayout4->addWidget(aGroupD2Widget, 1, 1); - - gridLayout1->addWidget(aGroup1SelWidget, 2, 0); - gridLayout1->addWidget(Group1Spin, 2, 0); - gridLayout1->addWidget(Group2Spin, 2, 0); - gridLayout1->addWidget(Group3Spin, 2, 0); - gridLayout1->addWidget(Group4Spin, 2, 0); + Group1Spin = new EntityGUI_1Spin( MainWidget->SkeletonCnt ); + Group1Spin->GroupBox1->setTitle( tr( "GEOM_SKETCHER_VALUES" ) ); + Group1Spin->buttonApply->setText( tr( "GEOM_SKETCHER_APPLY" ) ); + Group1Spin->buttonUndo->setIcon( image1 ); + Group1Spin->buttonRedo->setIcon( image2 ); + + Group2Spin = new EntityGUI_2Spin( MainWidget->SkeletonCnt ); + Group2Spin->GroupBox1->setTitle( tr( "GEOM_SKETCHER_VALUES" ) ); + Group2Spin->buttonApply->setText( tr( "GEOM_SKETCHER_APPLY" ) ); + Group2Spin->buttonUndo->setIcon( image1 ); + Group2Spin->buttonRedo->setIcon( image2 ); + + Group3Spin = new EntityGUI_3Spin( MainWidget->SkeletonCnt ); + Group3Spin->GroupBox1->setTitle( tr( "GEOM_SKETCHER_VALUES" ) ); + Group3Spin->buttonApply->setText( tr( "GEOM_SKETCHER_APPLY" ) ); + Group3Spin->buttonUndo->setIcon( image1 ); + Group3Spin->buttonRedo->setIcon( image2 ); + + Group4Spin = new EntityGUI_4Spin( MainWidget->SkeletonCnt ); + Group4Spin->GroupBox1->setTitle( tr( "GEOM_SKETCHER_VALUES" ) ); + Group4Spin->buttonApply->setText( tr( "GEOM_SKETCHER_APPLY" ) ); + Group4Spin->buttonUndo->setIcon( image1 ); + Group4Spin->buttonRedo->setIcon( image2 ); + + QGridLayout* DestCntLayout = new QGridLayout( MainWidget->DestCnt ); + DestCntLayout->setMargin( 0 ); DestCntLayout->setSpacing( 6 ); + DestCntLayout->addWidget( GroupPt, 0, 0, 1, 2 ); + DestCntLayout->addWidget( GroupD1, 1, 0 ); + DestCntLayout->addWidget( GroupD2, 1, 1 ); + + QVBoxLayout* SkeletonCntlayout = new QVBoxLayout( MainWidget->SkeletonCnt ); + SkeletonCntlayout->setMargin( 0 ); SkeletonCntlayout->setSpacing( 6 ); + SkeletonCntlayout->addWidget( Group1Sel, 0, 0 ); + SkeletonCntlayout->addWidget( Group1Spin, 0, 0 ); + SkeletonCntlayout->addWidget( Group2Spin, 0, 0 ); + SkeletonCntlayout->addWidget( Group3Spin, 0, 0 ); + SkeletonCntlayout->addWidget( Group4Spin, 0, 0 ); /***************************************************************/ + QButtonGroup* ButtonGroup = new QButtonGroup( this ); + ButtonGroup->addButton( MainWidget->RB_Dest1, 1 ); + ButtonGroup->addButton( MainWidget->RB_Dest2, 0 ); + /* signals and slots connections */ - connect(buttonEnd, SIGNAL(clicked()), this, SLOT(ClickOnEnd())); - connect(buttonClose, SIGNAL(clicked()), this, SLOT(ClickOnEnd())); - connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel())); - connect(buttonHelp, SIGNAL( clicked() ), this, SLOT( ClickOnHelp())); - - connect(Group1Sel->buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); - connect(Group1Sel->buttonUndo, SIGNAL(clicked()), this, SLOT(ClickOnUndo())); - connect(Group1Sel->buttonRedo, SIGNAL(clicked()), this, SLOT(ClickOnRedo())); - connect(Group1Spin->buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); - connect(Group1Spin->buttonUndo, SIGNAL(clicked()), this, SLOT(ClickOnUndo())); - connect(Group1Spin->buttonRedo, SIGNAL(clicked()), this, SLOT(ClickOnRedo())); - connect(Group2Spin->buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); - connect(Group2Spin->buttonUndo, SIGNAL(clicked()), this, SLOT(ClickOnUndo())); - connect(Group2Spin->buttonRedo, SIGNAL(clicked()), this, SLOT(ClickOnRedo())); - connect(Group3Spin->buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); - connect(Group3Spin->buttonUndo, SIGNAL(clicked()), this, SLOT(ClickOnUndo())); - connect(Group3Spin->buttonRedo, SIGNAL(clicked()), this, SLOT(ClickOnRedo())); - connect(Group4Spin->buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); - connect(Group4Spin->buttonUndo, SIGNAL(clicked()), this, SLOT(ClickOnUndo())); - connect(Group4Spin->buttonRedo, SIGNAL(clicked()), this, SLOT(ClickOnRedo())); - - connect(GroupConstructors, SIGNAL(clicked(int)), this, SLOT(TypeClicked(int))); - connect(GroupDest1, SIGNAL(clicked(int)), this, SLOT(DestClicked(int))); - connect(GroupPt->GroupPoint, SIGNAL(clicked(int)), this, SLOT(PointClicked(int))); - connect(GroupD1->GroupDir1, SIGNAL(clicked(int)), this, SLOT(Dir1Clicked(int))); - connect(GroupD2->GroupDir2, SIGNAL(clicked(int)), this, SLOT(Dir2Clicked(int))); - - connect(Group1Sel->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed())); - connect(Group1Sel->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument())); - - connect(Group1Spin->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group2Spin->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group2Spin->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group3Spin->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group3Spin->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group3Spin->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group4Spin->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group4Spin->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group4Spin->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - connect(Group4Spin->SpinBox_DS, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double))); - - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group1Spin->SpinBox_DX, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group2Spin->SpinBox_DX, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group2Spin->SpinBox_DY, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group3Spin->SpinBox_DX, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group3Spin->SpinBox_DY, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group3Spin->SpinBox_DZ, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group4Spin->SpinBox_DX, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group4Spin->SpinBox_DY, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group4Spin->SpinBox_DZ, SLOT(SetStep(double))); - connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group4Spin->SpinBox_DS, SLOT(SetStep(double))); - - connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog())); - connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel())); - - // install event filter on spin-boxes to provide Apply action on Return pressed - Group1Spin->SpinBox_DX->installEventFilter(this); - Group2Spin->SpinBox_DX->installEventFilter(this); - Group2Spin->SpinBox_DY->installEventFilter(this); - Group3Spin->SpinBox_DX->installEventFilter(this); - Group3Spin->SpinBox_DY->installEventFilter(this); - Group3Spin->SpinBox_DZ->installEventFilter(this); - Group4Spin->SpinBox_DX->installEventFilter(this); - Group4Spin->SpinBox_DY->installEventFilter(this); - Group4Spin->SpinBox_DZ->installEventFilter(this); - Group4Spin->SpinBox_DS->installEventFilter(this); + connect( MainWidget->buttonEnd, SIGNAL( clicked() ), this, SLOT( ClickOnEnd() ) ); + connect( MainWidget->buttonClose, SIGNAL( clicked() ), this, SLOT( ClickOnEnd() ) ); + connect( MainWidget->buttonCancel, SIGNAL( clicked() ), this, SLOT( ClickOnCancel() ) ); + connect( MainWidget->buttonHelp, SIGNAL( clicked() ), this, SLOT( ClickOnHelp() ) ); + + connect( Group1Sel->buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); + connect( Group1Sel->buttonUndo, SIGNAL( clicked() ), this, SLOT( ClickOnUndo() ) ); + connect( Group1Sel->buttonRedo, SIGNAL( clicked() ), this, SLOT( ClickOnRedo() ) ); + connect( Group1Spin->buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); + connect( Group1Spin->buttonUndo, SIGNAL( clicked() ), this, SLOT( ClickOnUndo() ) ); + connect( Group1Spin->buttonRedo, SIGNAL( clicked() ), this, SLOT( ClickOnRedo() ) ); + connect( Group2Spin->buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); + connect( Group2Spin->buttonUndo, SIGNAL( clicked() ), this, SLOT( ClickOnUndo() ) ); + connect( Group2Spin->buttonRedo, SIGNAL( clicked() ), this, SLOT( ClickOnRedo() ) ); + connect( Group3Spin->buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); + connect( Group3Spin->buttonUndo, SIGNAL( clicked() ), this, SLOT( ClickOnUndo() ) ); + connect( Group3Spin->buttonRedo, SIGNAL( clicked() ), this, SLOT( ClickOnRedo() ) ) ; + connect( Group4Spin->buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); + connect( Group4Spin->buttonUndo, SIGNAL( clicked() ), this, SLOT( ClickOnUndo() ) ); + connect( Group4Spin->buttonRedo, SIGNAL( clicked() ), this, SLOT( ClickOnRedo() ) ); + + connect( MainWidget->ButtonGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( TypeClicked( int ) ) ); + connect( ButtonGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( DestClicked( int ) ) ); + connect( GroupPt->ButtonGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( PointClicked( int ) ) ); + connect( GroupD1->ButtonGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( Dir1Clicked( int ) ) ); + connect( GroupD2->ButtonGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( Dir2Clicked( int ) )); + + connect( Group1Sel->LineEdit1, SIGNAL( returnPressed() ), this, SLOT( LineEditReturnPressed() ) ); + connect( Group1Sel->PushButton1, SIGNAL( clicked() ), this, SLOT( SetEditCurrentArgument() ) ); + + connect( Group1Spin->SpinBox_DX, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group2Spin->SpinBox_DX, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group2Spin->SpinBox_DY, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group3Spin->SpinBox_DX, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group3Spin->SpinBox_DY, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group3Spin->SpinBox_DZ, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group4Spin->SpinBox_DX, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group4Spin->SpinBox_DY, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group4Spin->SpinBox_DZ, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + connect( Group4Spin->SpinBox_DS, SIGNAL( valueChanged( double ) ), this, SLOT( ValueChangedInSpinBox( double ) ) ); + + // VSR: TODO ->> + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group1Spin->SpinBox_DX, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group2Spin->SpinBox_DX, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group2Spin->SpinBox_DY, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group3Spin->SpinBox_DX, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group3Spin->SpinBox_DY, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group3Spin->SpinBox_DZ, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group4Spin->SpinBox_DX, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group4Spin->SpinBox_DY, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group4Spin->SpinBox_DZ, SLOT( SetStep( double ) ) ); + connect( myGeometryGUI, SIGNAL( SignalDefaultStepValueChanged( double ) ), Group4Spin->SpinBox_DS, SLOT( SetStep( double ) ) ); + // <<- + + connect( myGeometryGUI, SIGNAL( SignalDeactivateActiveDialog() ), this, SLOT( DeactivateActiveDialog() ) ); + connect( myGeometryGUI, SIGNAL( SignalCloseAllDialogs() ), this, SLOT( ClickOnCancel() ) ); + + connect( Group1Spin->SpinBox_DX, SIGNAL( editingFinished() ), + Group1Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group2Spin->SpinBox_DX, SIGNAL( editingFinished() ), + Group2Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group2Spin->SpinBox_DY, SIGNAL( editingFinished() ), + Group2Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group3Spin->SpinBox_DX, SIGNAL( editingFinished() ), + Group3Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group3Spin->SpinBox_DY, SIGNAL( editingFinished() ), + Group3Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group3Spin->SpinBox_DZ, SIGNAL( editingFinished() ), + Group3Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group4Spin->SpinBox_DX, SIGNAL( editingFinished() ), + Group4Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group4Spin->SpinBox_DY, SIGNAL( editingFinished() ), + Group4Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group4Spin->SpinBox_DZ, SIGNAL( editingFinished() ), + Group4Spin->buttonApply, SLOT( animateClick() ) ); + connect( Group4Spin->SpinBox_DS, SIGNAL( editingFinished() ), + Group4Spin->buttonApply, SLOT( animateClick() ) ); Init(); } @@ -295,41 +263,6 @@ EntityGUI_SketcherDlg::~EntityGUI_SketcherDlg() } -//================================================================================= -// function : eventFilter() -// purpose : event filter for spin-boxes to provide Apply action on Return pressed -//================================================================================= -bool EntityGUI_SketcherDlg::eventFilter (QObject* object, QEvent* event) -{ - if (event->type() == QEvent::KeyPress) { - QKeyEvent* ke = (QKeyEvent*)event; - if (ke->key() == Qt::Key_Return) { - if (object == Group1Spin->SpinBox_DX) { - Group1Spin->buttonApply->animateClick(); - return true; - } else if (object == Group2Spin->SpinBox_DX || - object == Group2Spin->SpinBox_DY) { - Group2Spin->buttonApply->animateClick(); - return true; - } else if (object == Group3Spin->SpinBox_DX || - object == Group3Spin->SpinBox_DY || - object == Group3Spin->SpinBox_DZ) { - Group3Spin->buttonApply->animateClick(); - return true; - } else if (object == Group4Spin->SpinBox_DX || - object == Group4Spin->SpinBox_DY || - object == Group4Spin->SpinBox_DZ || - object == Group4Spin->SpinBox_DS) { - Group4Spin->buttonApply->animateClick(); - return true; - } - } - } - - return QDialog::eventFilter(object, event); -} - - //================================================================================= // function : Init() // purpose : @@ -355,29 +288,29 @@ void EntityGUI_SketcherDlg::Init() double step = SUIT_Session::session()->resourceMgr()->doubleValue( "Geometry", "SettingsGeomStep", 100.0 ); /* min, max, step and decimals for spin boxes */ - Group1Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group3Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group3Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group3Spin->SpinBox_DZ->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group4Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, 0.1, 3); - Group4Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, 0.1, 3); - Group4Spin->SpinBox_DZ->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group4Spin->SpinBox_DS->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); + initSpinBox( Group1Spin->SpinBox_DX, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DX, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group3Spin->SpinBox_DX, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group3Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group3Spin->SpinBox_DZ, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group4Spin->SpinBox_DX, COORD_MIN, COORD_MAX, 0.1, 3 ); + initSpinBox( Group4Spin->SpinBox_DY, COORD_MIN, COORD_MAX, 0.1, 3 ); + initSpinBox( Group4Spin->SpinBox_DZ, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group4Spin->SpinBox_DS, COORD_MIN, COORD_MAX, 5., 3 ); /* displays Dialog */ - GroupConstructors->setEnabled(false); - GroupDest1->setEnabled(false); - setEnabledUndo(false); - setEnabledRedo(false); + MainWidget->GroupConstructors->setEnabled( false ); + MainWidget->GroupDest1->setEnabled( false ); + setEnabledUndo( false ); + setEnabledRedo( false ); - RadioButton1->setChecked(true); + MainWidget->RadioButton1->setChecked( true ); resize( 0, 0 ); - TypeClicked(0); + TypeClicked( 0 ); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } @@ -387,15 +320,15 @@ void EntityGUI_SketcherDlg::Init() //================================================================================= void EntityGUI_SketcherDlg::InitClick() { - disconnect(myGeometryGUI->getApp()->selectionMgr(), 0, this, 0); + disconnect( myGeometryGUI->getApp()->selectionMgr(), 0, this, 0 ); - ::qobject_cast( Group1Sel->gridLayout->parent() )->hide(); + Group1Sel->hide(); Group1Spin->hide(); Group2Spin->hide(); Group3Spin->hide(); Group4Spin->hide(); - resize(0, 0); + resize( 0, 0 ); } @@ -403,22 +336,20 @@ void EntityGUI_SketcherDlg::InitClick() // function : TypeClicked() // purpose : Radio button management //================================================================================= -void EntityGUI_SketcherDlg::TypeClicked(int constructorId) +void EntityGUI_SketcherDlg::TypeClicked( int constructorId ) { myConstructorId = constructorId; - if ( myConstructorId == 0 ) // SEGMENT - { - ::qobject_cast( GroupD2->gridLayout->parent() )->setEnabled(true); - RB_Dest1->setEnabled(true); - RB_Dest1->setChecked(true); - DestClicked(1); + if ( myConstructorId == 0 ) { // SEGMENT + GroupD2->setEnabled( true ); + MainWidget->RB_Dest1->setEnabled( true ); + MainWidget->RB_Dest1->setChecked( true ); + DestClicked( 1 ); } - else if ( myConstructorId == 1 ) // ARC - { - ::qobject_cast( GroupD2->gridLayout->parent() )->setEnabled(false); - RB_Dest1->setEnabled(false); - RB_Dest2->setChecked(true); - DestClicked(0); + else if ( myConstructorId == 1 ) { // ARC + GroupD2->setEnabled( false ); + MainWidget->RB_Dest1->setEnabled( false ); + MainWidget->RB_Dest2->setChecked( true ); + DestClicked( 0 ); } } @@ -429,22 +360,22 @@ void EntityGUI_SketcherDlg::TypeClicked(int constructorId) //================================================================================= void EntityGUI_SketcherDlg::DestClicked( int constructorId ) { - ::qobject_cast( GroupPt->gridLayout->parent() )->hide(); - ::qobject_cast( GroupD1->gridLayout->parent() )->hide(); - ::qobject_cast( GroupD2->gridLayout->parent() )->hide(); - - if ( constructorId == 1 ) - { // Point - GroupPt->RB_Point1->setChecked(true); - ::qobject_cast( GroupPt->gridLayout->parent() )->show(); - PointClicked(1); // XY + GroupPt->hide(); + GroupD1->hide(); + GroupD2->hide(); + + if ( constructorId == 1 ) { + // Point + GroupPt->RB_Point1->setChecked( true ); + GroupPt->show(); + PointClicked( 1 ); // XY } - else if ( constructorId == 0 ) - { // Direction - GroupD1->RB_Dir11->setChecked(true); - ::qobject_cast( GroupD1->gridLayout->parent() )->show(); - ::qobject_cast( GroupD2->gridLayout->parent() )->show(); - Dir1Clicked(2); // Angle + else if ( constructorId == 0 ) { + // Direction + GroupD1->RB_Dir11->setChecked( true ); + GroupD1->show(); + GroupD2->show(); + Dir1Clicked( 2 ); // Angle } } @@ -453,54 +384,50 @@ void EntityGUI_SketcherDlg::DestClicked( int constructorId ) // function : PointClicked() // purpose : Radio button management //================================================================================= -void EntityGUI_SketcherDlg::PointClicked(int constructorId) +void EntityGUI_SketcherDlg::PointClicked( int constructorId ) { InitClick(); // Get setting of step value from file configuration - double step = SUIT_Session::session()->resourceMgr()->doubleValue("Geometry", "SettingsGeomStep", 100.0); + double step = SUIT_Session::session()->resourceMgr()->doubleValue( "Geometry", "SettingsGeomStep", 100.0 ); - if ( myConstructorId == 0 ) - { // SEGMENT - if ( constructorId == 1 ) - { // XY + if ( myConstructorId == 0 ) { // SEGMENT + if ( constructorId == 1 ) { // XY mySketchType = PT_ABS; - Group2Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->TextLabel1->setText(tr("GEOM_SKETCHER_X2")); - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_Y2")); + initSpinBox( Group2Spin->SpinBox_DX, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + Group2Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_X2" ) ); + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_Y2" ) ); myX = 0.0; - Group2Spin->SpinBox_DX->SetValue(myX); + Group2Spin->SpinBox_DX->setValue( myX ); myY = 0.0; - Group2Spin->SpinBox_DY->SetValue(myY); + Group2Spin->SpinBox_DY->setValue( myY ); Group2Spin->show(); Group2Spin->buttonApply->setFocus(); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } - else if ( constructorId == 0 ) - { // DXDY + else if ( constructorId == 0 ) { // DXDY mySketchType = PT_RELATIVE; - Group2Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->TextLabel1->setText(tr("GEOM_SKETCHER_DX2")); - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_DY2")); + initSpinBox( Group2Spin->SpinBox_DX, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + Group2Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_DX2" ) ); + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_DY2" ) ); myDX = 0.0; - Group2Spin->SpinBox_DX->SetValue(myDX); + Group2Spin->SpinBox_DX->setValue( myDX ); myDY = 0.0; - Group2Spin->SpinBox_DY->SetValue(myDY); + Group2Spin->SpinBox_DY->setValue( myDY ); Group2Spin->show(); Group2Spin->buttonApply->setFocus(); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } - else if ( constructorId == 2 ) - { // Selection + else if ( constructorId == 2 ) { // Selection mySketchType = PT_SEL; myEditCurrentArgument = Group1Sel->LineEdit1; - connect(myGeometryGUI->getApp()->selectionMgr(), - SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())); - ::qobject_cast( Group1Sel->gridLayout->parent() )->show(); + connect( myGeometryGUI->getApp()->selectionMgr(), + SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) ); + Group1Sel->show(); Group1Sel->buttonApply->setFocus(); SelectionIntoArgument(); } @@ -512,11 +439,11 @@ void EntityGUI_SketcherDlg::PointClicked(int constructorId) // function : Dir1Clicked() // purpose : Radio button management //================================================================================= -void EntityGUI_SketcherDlg::Dir1Clicked(int constructorId) +void EntityGUI_SketcherDlg::Dir1Clicked( int constructorId ) { myConstructorDirId = constructorId; - GroupD2->RB_Dir21->setChecked(true); - Dir2Clicked(2); + GroupD2->RB_Dir21->setChecked( true ); + Dir2Clicked( 2 ); } @@ -524,209 +451,183 @@ void EntityGUI_SketcherDlg::Dir1Clicked(int constructorId) // function : Dir2Clicked() // purpose : Radio button management //================================================================================= -void EntityGUI_SketcherDlg::Dir2Clicked(int constructorId) +void EntityGUI_SketcherDlg::Dir2Clicked( int constructorId ) { InitClick(); myAngle = 0.0; // Get setting of step value from file configuration - double step = SUIT_Session::session()->resourceMgr()->doubleValue("Geometry", "SettingsGeomStep", 100.0); + double step = SUIT_Session::session()->resourceMgr()->doubleValue( "Geometry", "SettingsGeomStep", 100.0 ); - if ( myConstructorId == 0 ) - { // SEGMENT + if ( myConstructorId == 0 ) { // SEGMENT myX = 0.0; myY = 0.0; myLength = 100.0; - if ( myConstructorDirId == 2 ) - { // Angle - Group2Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->TextLabel1->setText(tr("GEOM_SKETCHER_ANGLE2")); - Group2Spin->SpinBox_DX->SetValue(myAngle); + if ( myConstructorDirId == 2 ) { // Angle + initSpinBox( Group2Spin->SpinBox_DX, COORD_MIN, COORD_MAX, 5., 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + Group2Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_ANGLE2" ) ); + Group2Spin->SpinBox_DX->setValue( myAngle ); Group2Spin->buttonApply->setFocus(); Group2Spin->show(); - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_ANGLE_LENGTH; - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_LENGTH2")); - Group2Spin->SpinBox_DY->SetValue(myLength); + if ( constructorId == 2 ) { // Length + mySketchType = DIR_ANGLE_LENGTH; + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_LENGTH2" ) ); + Group2Spin->SpinBox_DY->setValue( myLength ); } - else if ( constructorId == 0 ) - { // X - mySketchType = DIR_ANGLE_X; - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_X3")); - Group2Spin->SpinBox_DY->SetValue(myX); + else if ( constructorId == 0 ) { // X + mySketchType = DIR_ANGLE_X; + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_X3" ) ); + Group2Spin->SpinBox_DY->setValue( myX ); } - else if ( constructorId == 1 ) - { // Y - mySketchType = DIR_ANGLE_Y; - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_Y3")); - Group2Spin->SpinBox_DY->SetValue(myY); + else if ( constructorId == 1 ) { // Y + mySketchType = DIR_ANGLE_Y; + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_Y3" ) ); + Group2Spin->SpinBox_DY->setValue( myY ); } } - else if ( myConstructorDirId == 0 ) - { // Perpendicular + else if ( myConstructorDirId == 0 ) { // Perpendicular Group1Spin->show(); Group1Spin->buttonApply->setFocus(); - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_PER_LENGTH; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_LENGTH2")); - Group1Spin->SpinBox_DX->SetValue(myLength); + if ( constructorId == 2 ) { // Length + mySketchType = DIR_PER_LENGTH; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_LENGTH2" ) ); + Group1Spin->SpinBox_DX->setValue( myLength ); } - else if ( constructorId == 0 ) - { // X - mySketchType = DIR_PER_X; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_X3")); - Group1Spin->SpinBox_DX->SetValue(myX); + else if ( constructorId == 0 ) { // X + mySketchType = DIR_PER_X; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_X3" ) ); + Group1Spin->SpinBox_DX->setValue( myX ); } - else if ( constructorId == 1 ) - { // Y - mySketchType = DIR_PER_Y; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_Y3")); - Group1Spin->SpinBox_DX->SetValue(myY); + else if ( constructorId == 1 ) { // Y + mySketchType = DIR_PER_Y; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_Y3" ) ); + Group1Spin->SpinBox_DX->setValue( myY ); } } - else if ( myConstructorDirId == 1 ) - { // Tangent + else if ( myConstructorDirId == 1 ) { // Tangent Group1Spin->show(); Group1Spin->buttonApply->setFocus(); - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_TAN_LENGTH; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_LENGTH2")); - Group1Spin->SpinBox_DX->SetValue(myLength); + if ( constructorId == 2 ) { // Length + mySketchType = DIR_TAN_LENGTH; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_LENGTH2" ) ); + Group1Spin->SpinBox_DX->setValue( myLength ); } - else if ( constructorId == 0 ) - { // X - mySketchType = DIR_TAN_X; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_X3")); - Group1Spin->SpinBox_DX->SetValue(myX); + else if ( constructorId == 0 ) { // X + mySketchType = DIR_TAN_X; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_X3" ) ); + Group1Spin->SpinBox_DX->setValue( myX ); } - else if ( constructorId == 1 ) - { // Y - mySketchType = DIR_TAN_Y; - Group1Spin->TextLabel1->setText(tr("GEOM_SKETCHER_Y3")); - Group1Spin->SpinBox_DX->SetValue(myY); + else if ( constructorId == 1 ) { // Y + mySketchType = DIR_TAN_Y; + Group1Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_Y3" ) ); + Group1Spin->SpinBox_DX->setValue( myY ); } } - else if ( myConstructorDirId == 3 ) - { // DXDY - Group3Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, 0.1, 3); - Group3Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, 0.1, 3); - Group3Spin->SpinBox_DZ->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group3Spin->TextLabel1->setText(tr("GEOM_SKETCHER_VX2")); - Group3Spin->TextLabel2->setText(tr("GEOM_SKETCHER_VY2")); + else if ( myConstructorDirId == 3 ) { // DXDY + initSpinBox( Group3Spin->SpinBox_DX, COORD_MIN, COORD_MAX, 0.1, 3 ); + initSpinBox( Group3Spin->SpinBox_DY, COORD_MIN, COORD_MAX, 0.1, 3 ); + initSpinBox( Group3Spin->SpinBox_DZ, COORD_MIN, COORD_MAX, step, 3 ); + Group3Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_VX2" ) ); + Group3Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_VY2" ) ); myDX = 0.0; - Group3Spin->SpinBox_DX->SetValue(myDX); + Group3Spin->SpinBox_DX->setValue( myDX ); myDY = 0.0; - Group3Spin->SpinBox_DY->SetValue(myDY); + Group3Spin->SpinBox_DY->setValue( myDY ); Group3Spin->show(); Group3Spin->buttonApply->setFocus(); - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_DXDY_LENGTH; - Group3Spin->TextLabel3->setText(tr("GEOM_SKETCHER_LENGTH2")); - Group3Spin->SpinBox_DZ->SetValue(myLength); + if ( constructorId == 2 ) { // Length + mySketchType = DIR_DXDY_LENGTH; + Group3Spin->TextLabel3->setText( tr( "GEOM_SKETCHER_LENGTH2" ) ); + Group3Spin->SpinBox_DZ->setValue( myLength ); } - else if ( constructorId == 0 ) - { // X - mySketchType = DIR_DXDY_X; - Group3Spin->TextLabel3->setText(tr("GEOM_SKETCHER_X3")); - Group3Spin->SpinBox_DZ->SetValue(myX); + else if ( constructorId == 0 ) { // X + mySketchType = DIR_DXDY_X; + Group3Spin->TextLabel3->setText( tr( "GEOM_SKETCHER_X3" ) ); + Group3Spin->SpinBox_DZ->setValue( myX ); } - else if ( constructorId == 1 ) - { // Y - mySketchType = DIR_DXDY_Y; - Group3Spin->TextLabel3->setText(tr("GEOM_SKETCHER_Y3")); - Group3Spin->SpinBox_DZ->SetValue(myY); + else if ( constructorId == 1 ) { // Y + mySketchType = DIR_DXDY_Y; + Group3Spin->TextLabel3->setText( tr( "GEOM_SKETCHER_Y3" ) ); + Group3Spin->SpinBox_DZ->setValue( myY ); } } } - else if ( myConstructorId == 1 ) - { // ARC - if ( myConstructorDirId == 2 ) - { // Angle - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_ANGLE_LENGTH; - Group3Spin->SpinBox_DX->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); - Group3Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group3Spin->SpinBox_DZ->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); - Group3Spin->TextLabel1->setText(tr("GEOM_SKETCHER_ANGLE2")); - Group3Spin->TextLabel2->setText(tr("GEOM_SKETCHER_RADIUS2")); - Group3Spin->TextLabel3->setText(tr("GEOM_SKETCHER_ANGLE2")); - Group3Spin->SpinBox_DX->SetValue(myAngle); - myRadius = 100.0; - Group3Spin->SpinBox_DY->SetValue(myRadius); - myLength = 30.0; - Group3Spin->SpinBox_DZ->SetValue(myLength); - Group3Spin->show(); - Group3Spin->buttonApply->setFocus(); + else if ( myConstructorId == 1 ) { // ARC + if ( myConstructorDirId == 2 ) { // Angle + if ( constructorId == 2 ) { // Length + mySketchType = DIR_ANGLE_LENGTH; + initSpinBox( Group3Spin->SpinBox_DX, COORD_MIN, COORD_MAX, 5., 3 ); + initSpinBox( Group3Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group3Spin->SpinBox_DZ, COORD_MIN, COORD_MAX, 5., 3 ); + Group3Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_ANGLE2" ) ); + Group3Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_RADIUS2" ) ); + Group3Spin->TextLabel3->setText( tr( "GEOM_SKETCHER_ANGLE2" )); + Group3Spin->SpinBox_DX->setValue( myAngle ); + myRadius = 100.0; + Group3Spin->SpinBox_DY->setValue( myRadius ); + myLength = 30.0; + Group3Spin->SpinBox_DZ->setValue( myLength ); + Group3Spin->show(); + Group3Spin->buttonApply->setFocus(); } } - else if ( myConstructorDirId == 0 ) - { // Perpendicular - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_PER_LENGTH; - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); - Group2Spin->TextLabel1->setText(tr("GEOM_SKETCHER_RADIUS2")); - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_ANGLE2")); - myRadius = 100.0; - Group2Spin->SpinBox_DX->SetValue(myRadius); - myLength = 30.0; - Group2Spin->SpinBox_DY->SetValue(myLength); - Group2Spin->show(); - Group2Spin->buttonApply->setFocus(); + else if ( myConstructorDirId == 0 ) { // Perpendicular + if ( constructorId == 2 ) { // Length + mySketchType = DIR_PER_LENGTH; + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, 5., 3 ); + Group2Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_RADIUS2" ) ); + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_ANGLE2" ) ); + myRadius = 100.0; + Group2Spin->SpinBox_DX->setValue( myRadius ); + myLength = 30.0; + Group2Spin->SpinBox_DY->setValue( myLength ); + Group2Spin->show(); + Group2Spin->buttonApply->setFocus(); } } - else if ( myConstructorDirId == 1 ) - { // Tangent - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_TAN_LENGTH; - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, step, 3); - Group2Spin->SpinBox_DY->RangeStepAndValidator(COORD_MIN, COORD_MAX, 5., 3); - Group2Spin->TextLabel1->setText(tr("GEOM_SKETCHER_RADIUS2")); - Group2Spin->TextLabel2->setText(tr("GEOM_SKETCHER_ANGLE2")); - myRadius = 100.0; - Group2Spin->SpinBox_DX->SetValue(myRadius); - myLength = 30.0; - Group2Spin->SpinBox_DY->SetValue(myLength); - Group2Spin->show(); - Group2Spin->buttonApply->setFocus(); + else if ( myConstructorDirId == 1 ) { // Tangent + if ( constructorId == 2 ) { // Length + mySketchType = DIR_TAN_LENGTH; + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, step, 3 ); + initSpinBox( Group2Spin->SpinBox_DY, COORD_MIN, COORD_MAX, 5., 3 ); + Group2Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_RADIUS2" ) ); + Group2Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_ANGLE2" ) ); + myRadius = 100.0; + Group2Spin->SpinBox_DX->setValue( myRadius ); + myLength = 30.0; + Group2Spin->SpinBox_DY->setValue( myLength ); + Group2Spin->show(); + Group2Spin->buttonApply->setFocus(); } } - else if ( myConstructorDirId == 3 ) - { // DXDY - if ( constructorId == 2 ) - { // Length - mySketchType = DIR_DXDY_LENGTH; - Group4Spin->TextLabel1->setText(tr("GEOM_SKETCHER_VX2")); - Group4Spin->TextLabel2->setText(tr("GEOM_SKETCHER_VY2")); - Group4Spin->TextLabel3->setText(tr("GEOM_SKETCHER_RADIUS2")); - Group4Spin->TextLabel4->setText(tr("GEOM_SKETCHER_ANGLE2")); - myDX = 0.0; - Group4Spin->SpinBox_DX->SetValue(myDX); - myDY = 0.0; - Group4Spin->SpinBox_DY->SetValue(myDY); - myRadius = 100.0; - Group4Spin->SpinBox_DZ->SetValue(myRadius); - myLength = 30.0; - Group4Spin->SpinBox_DS->SetValue(myLength); - Group4Spin->show(); - Group4Spin->buttonApply->setFocus(); + else if ( myConstructorDirId == 3 ) { // DXDY + if ( constructorId == 2 ) { // Length + mySketchType = DIR_DXDY_LENGTH; + Group4Spin->TextLabel1->setText( tr( "GEOM_SKETCHER_VX2" ) ); + Group4Spin->TextLabel2->setText( tr( "GEOM_SKETCHER_VY2" ) ); + Group4Spin->TextLabel3->setText( tr( "GEOM_SKETCHER_RADIUS2" ) ); + Group4Spin->TextLabel4->setText( tr( "GEOM_SKETCHER_ANGLE2" ) ); + myDX = 0.0; + Group4Spin->SpinBox_DX->setValue( myDX ); + myDY = 0.0; + Group4Spin->SpinBox_DY->setValue( myDY ); + myRadius = 100.0; + Group4Spin->SpinBox_DZ->setValue( myRadius ); + myLength = 30.0; + Group4Spin->SpinBox_DS->setValue( myLength ); + Group4Spin->show(); + Group4Spin->buttonApply->setFocus(); } } } - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } @@ -746,33 +647,31 @@ void EntityGUI_SketcherDlg::ClickOnCancel() //================================================================================= void EntityGUI_SketcherDlg::ClickOnEnd() { - if ( sender() == buttonClose ) - { + if ( sender() == MainWidget->buttonClose ) { // Verify validity of commands - if ( myCommand.count() <= 2 ) - { + if ( myCommand.count() <= 2 ) { SUIT_MessageBox::critical( SUIT_Session::session()->activeApplication()->desktop(), tr( "GEOM_ERROR_STATUS" ), tr( "CANNOT_CLOSE" ), tr( "BUT_OK" ) ); return; } QString Command = myCommand.join( "" ) + GetNewCommand(); - Sketcher_Profile aProfile (Command.toAscii()); + Sketcher_Profile aProfile( Command.toAscii() ); Command = myCommand.join( "" ); - aProfile = Sketcher_Profile(Command.toAscii()); + aProfile = Sketcher_Profile( Command.toAscii() ); TopoDS_Shape myShape; if ( aProfile.IsDone() ) myShape = aProfile.GetShape(); - if(myShape.ShapeType() != TopAbs_VERTEX) + if ( myShape.ShapeType() != TopAbs_VERTEX ) myCommand.append( ":WW" ); } else myIsAllAdded = true; - if( myCommand.size() > 2 ) - if( !onAccept() ) + if ( myCommand.size() > 2 ) + if ( !onAccept() ) return; close(); @@ -792,27 +691,27 @@ bool EntityGUI_SketcherDlg::ClickOnApply() myUndoCommand.clear(); myUndoCommand.append( "Sketcher" ); - GroupConstructors->setEnabled(true); - GroupDest1->setEnabled(true); - setEnabledUndo(true); - setEnabledRedo(false); + MainWidget->GroupConstructors->setEnabled( true ); + MainWidget->GroupDest1->setEnabled( true ); + setEnabledUndo( true ); + setEnabledRedo( false ); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); // Set focus to SpinBox_DX - if (sender() == Group1Spin->buttonApply) { + if ( sender() == Group1Spin->buttonApply ) { (Group1Spin->SpinBox_DX)->setFocus(); (Group1Spin->SpinBox_DX)->selectAll(); } - else if (sender() == Group2Spin->buttonApply) { + else if ( sender() == Group2Spin->buttonApply ) { (Group2Spin->SpinBox_DX)->setFocus(); (Group2Spin->SpinBox_DX)->selectAll(); } - else if (sender() == Group3Spin->buttonApply) { + else if ( sender() == Group3Spin->buttonApply ) { (Group3Spin->SpinBox_DX)->setFocus(); (Group3Spin->SpinBox_DX)->selectAll(); } - else if (sender() == Group4Spin->buttonApply) { + else if ( sender() == Group4Spin->buttonApply ) { (Group4Spin->SpinBox_DX)->setFocus(); (Group4Spin->SpinBox_DX)->selectAll(); } @@ -826,21 +725,21 @@ bool EntityGUI_SketcherDlg::ClickOnApply() //================================================================================= void EntityGUI_SketcherDlg::ClickOnHelp() { - LightApp_Application* app = (LightApp_Application*)(SUIT_Session::session()->activeApplication()); - if (app) - app->onHelpContextModule(myGeometryGUI ? app->moduleName(myGeometryGUI->moduleName()) : QString(""), myHelpFileName); + LightApp_Application* app = (LightApp_Application*)( SUIT_Session::session()->activeApplication() ); + if ( app ) + app->onHelpContextModule( myGeometryGUI ? app->moduleName( myGeometryGUI->moduleName() ) : QString( "" ), myHelpFileName ); else { - QString platform; + QString platform; #ifdef WIN32 - platform = "winapplication"; + platform = "winapplication"; #else - platform = "application"; + platform = "application"; #endif - SUIT_MessageBox::warning(0, QObject::tr("WRN_WARNING"), - QObject::tr("EXTERNAL_BROWSER_CANNOT_SHOW_PAGE"). - arg(app->resourceMgr()->stringValue("ExternalBrowser", platform)).arg(myHelpFileName), - QObject::tr("BUT_OK")); + SUIT_MessageBox::warning( 0, QObject::tr( "WRN_WARNING" ), + QObject::tr( "EXTERNAL_BROWSER_CANNOT_SHOW_PAGE" ). + arg( app->resourceMgr()->stringValue( "ExternalBrowser", platform ) ).arg( myHelpFileName ), + QObject::tr( "BUT_OK" ) ); } } @@ -853,20 +752,20 @@ void EntityGUI_SketcherDlg::ClickOnUndo() myUndoCommand.append( myCommand.last() ); myCommand.pop_back(); - if(myCommand.count() == 1) { + if ( myCommand.count() == 1 ) { mySketchState = FIRST_POINT; - RadioButton1->setChecked(true); - TypeClicked(0); + MainWidget->RadioButton1->setChecked( true ); + TypeClicked( 0 ); - GroupConstructors->setEnabled(false); - GroupDest1->setEnabled(false); - setEnabledUndo(false); + MainWidget->GroupConstructors->setEnabled( false ); + MainWidget->GroupDest1->setEnabled( false ); + setEnabledUndo( false ); } - setEnabledRedo(true); + setEnabledRedo( true ); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } //================================================================================= @@ -880,40 +779,40 @@ void EntityGUI_SketcherDlg::ClickOnRedo() mySketchState = NEXT_POINT; - GroupConstructors->setEnabled(true); - GroupDest1->setEnabled(true); - setEnabledUndo(true); + MainWidget->GroupConstructors->setEnabled( true ); + MainWidget->GroupDest1->setEnabled( true ); + setEnabledUndo( true ); - if(myUndoCommand.count() == 1) - setEnabledRedo(false); + if ( myUndoCommand.count() == 1 ) + setEnabledRedo( false ); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } //================================================================================= // function : setEnabledUndo() // purpose : //================================================================================= -void EntityGUI_SketcherDlg::setEnabledUndo(bool value) +void EntityGUI_SketcherDlg::setEnabledUndo( bool value ) { - Group1Sel->buttonUndo->setEnabled(value); - Group1Spin->buttonUndo->setEnabled(value); - Group2Spin->buttonUndo->setEnabled(value); - Group3Spin->buttonUndo->setEnabled(value); - Group4Spin->buttonUndo->setEnabled(value); + Group1Sel->buttonUndo->setEnabled( value ); + Group1Spin->buttonUndo->setEnabled( value ); + Group2Spin->buttonUndo->setEnabled( value ); + Group3Spin->buttonUndo->setEnabled( value ); + Group4Spin->buttonUndo->setEnabled( value ); } //================================================================================= // function : setEnabledRedo() // purpose : //================================================================================= -void EntityGUI_SketcherDlg::setEnabledRedo(bool value) +void EntityGUI_SketcherDlg::setEnabledRedo( bool value ) { - Group1Sel->buttonRedo->setEnabled(value); - Group1Spin->buttonRedo->setEnabled(value); - Group2Spin->buttonRedo->setEnabled(value); - Group3Spin->buttonRedo->setEnabled(value); - Group4Spin->buttonRedo->setEnabled(value); + Group1Sel->buttonRedo->setEnabled( value ); + Group1Spin->buttonRedo->setEnabled( value ); + Group2Spin->buttonRedo->setEnabled( value ); + Group3Spin->buttonRedo->setEnabled( value ); + Group4Spin->buttonRedo->setEnabled( value ); } //================================================================================= @@ -922,13 +821,12 @@ void EntityGUI_SketcherDlg::setEnabledRedo(bool value) //================================================================================= void EntityGUI_SketcherDlg::SelectionIntoArgument() { - myEditCurrentArgument->setText(""); + myEditCurrentArgument->setText( "" ); myX = myLastX1; myY = myLastY1; int nbSel = IObjectCount(); - if ( nbSel == 1 && myEditCurrentArgument == Group1Sel->LineEdit1 ) - { + if ( nbSel == 1 && myEditCurrentArgument == Group1Sel->LineEdit1 ) { Standard_Boolean aRes = Standard_False; GEOM::GEOM_Object_var aSelectedObject = GEOMBase::ConvertIOinGEOMObject( firstIObject(), aRes ); if ( !CORBA::is_nil( aSelectedObject ) && aRes ) { @@ -937,8 +835,8 @@ void EntityGUI_SketcherDlg::SelectionIntoArgument() gp_Trsf aTrans; gp_Ax3 aWPlane = myGeometryGUI->GetWorkingPlane(); - aTrans.SetTransformation(aWPlane); - BRepBuilderAPI_Transform aTransformation(aShape, aTrans, Standard_False); + aTrans.SetTransformation( aWPlane ); + BRepBuilderAPI_Transform aTransformation( aShape, aTrans, Standard_False ); aShape = aTransformation.Shape(); gp_Pnt aPnt; @@ -951,7 +849,7 @@ void EntityGUI_SketcherDlg::SelectionIntoArgument() } } - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } @@ -961,8 +859,7 @@ void EntityGUI_SketcherDlg::SelectionIntoArgument() //================================================================================= void EntityGUI_SketcherDlg::SetEditCurrentArgument() { - if ( sender() == Group1Sel->PushButton1 ) - { + if ( sender() == Group1Sel->PushButton1 ) { myEditCurrentArgument = Group1Sel->LineEdit1; myEditCurrentArgument->setFocus(); } @@ -976,17 +873,16 @@ void EntityGUI_SketcherDlg::SetEditCurrentArgument() //================================================================================= void EntityGUI_SketcherDlg::LineEditReturnPressed() { - if ( sender() == Group1Sel->LineEdit1 ) - { + if ( sender() == Group1Sel->LineEdit1 ) { myEditCurrentArgument = Group1Sel->LineEdit1; - /* User name of object input management */ - /* If successfull the selection is changed and signal emitted... */ - /* so SelectionIntoArgument() is automatically called. */ - const QString objectUserName = myEditCurrentArgument->text(); - QWidget* thisWidget = (QWidget*)this; - if(GEOMBase::SelectionByNameInDialogs(thisWidget, objectUserName, selectedIO())) - myEditCurrentArgument->setText(objectUserName); + /* User name of object input management */ + /* If successfull the selection is changed and signal emitted... */ + /* so SelectionIntoArgument() is automatically called. */ + const QString objectUserName = myEditCurrentArgument->text(); + QWidget* thisWidget = (QWidget*)this; + if ( GEOMBase::SelectionByNameInDialogs( thisWidget, objectUserName, selectedIO() ) ) + myEditCurrentArgument->setText( objectUserName ); } } @@ -1001,8 +897,8 @@ void EntityGUI_SketcherDlg::DeactivateActiveDialog() setEnabled( false ); globalSelection(); - disconnect(myGeometryGUI->getApp()->selectionMgr(), 0, this, 0); - myGeometryGUI->SetActiveDialogBox(0); + disconnect( myGeometryGUI->getApp()->selectionMgr(), 0, this, 0 ); + myGeometryGUI->SetActiveDialogBox( 0 ); } @@ -1013,11 +909,11 @@ void EntityGUI_SketcherDlg::DeactivateActiveDialog() void EntityGUI_SketcherDlg::ActivateThisDialog() { myGeometryGUI->EmitSignalDeactivateDialog(); - setEnabled(true); - myGeometryGUI->SetActiveDialogBox((QDialog*)this); + setEnabled( true ); + myGeometryGUI->SetActiveDialogBox( this ); - connect(myGeometryGUI->getApp()->selectionMgr(), - SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())); + connect( myGeometryGUI->getApp()->selectionMgr(), + SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) ); //myGeometryGUI->SetState( 0 ); globalSelection( GEOM_POINT ); @@ -1025,7 +921,7 @@ void EntityGUI_SketcherDlg::ActivateThisDialog() myEditCurrentArgument = Group1Sel->LineEdit1; myEditCurrentArgument->setFocus(); - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } @@ -1033,9 +929,9 @@ void EntityGUI_SketcherDlg::ActivateThisDialog() // function : enterEvent [REDEFINED] // purpose : //================================================================================= -void EntityGUI_SketcherDlg::enterEvent(QEvent* e) +void EntityGUI_SketcherDlg::enterEvent( QEvent* ) { - if ( !GroupConstructors->isEnabled()) + if ( !MainWidget->GroupConstructors->isEnabled() ) ActivateThisDialog(); } @@ -1044,10 +940,10 @@ void EntityGUI_SketcherDlg::enterEvent(QEvent* e) // function : closeEvent() // purpose : //================================================================================= -void EntityGUI_SketcherDlg::closeEvent(QCloseEvent* e) +void EntityGUI_SketcherDlg::closeEvent( QCloseEvent* e ) { //myGeometryGUI->SetState( -1 ); - disconnect(myGeometryGUI->getApp()->selectionMgr(), 0, this, 0); + disconnect( myGeometryGUI->getApp()->selectionMgr(), 0, this, 0 ); QDialog::closeEvent( e ); } @@ -1056,163 +952,133 @@ void EntityGUI_SketcherDlg::closeEvent(QCloseEvent* e) // function : ValueChangedInSpinBox() // purpose : //================================================================================= -void EntityGUI_SketcherDlg::ValueChangedInSpinBox(double newValue) +void EntityGUI_SketcherDlg::ValueChangedInSpinBox( double newValue ) { QObject* send = (QObject*)sender(); Standard_Real vx, vy, vz, vs; vx = vy = vz = vs = 0.0; - if ( send == Group1Spin->SpinBox_DX) - { + if ( send == Group1Spin->SpinBox_DX ) { vx = newValue; } - else if ( send == Group2Spin->SpinBox_DX ) - { + else if ( send == Group2Spin->SpinBox_DX ) { vx = newValue; - vy = Group2Spin->SpinBox_DY->GetValue(); + vy = Group2Spin->SpinBox_DY->value(); } - else if ( send == Group2Spin->SpinBox_DY) - { - vx = Group2Spin->SpinBox_DX->GetValue(); + else if ( send == Group2Spin->SpinBox_DY ) { + vx = Group2Spin->SpinBox_DX->value(); vy = newValue; } - else if ( send == Group3Spin->SpinBox_DX) - { + else if ( send == Group3Spin->SpinBox_DX ) { vx = newValue; - vy = Group3Spin->SpinBox_DY->GetValue(); - vz = Group3Spin->SpinBox_DZ->GetValue(); + vy = Group3Spin->SpinBox_DY->value(); + vz = Group3Spin->SpinBox_DZ->value(); } - else if ( send == Group3Spin->SpinBox_DY) - { - vx = Group3Spin->SpinBox_DX->GetValue(); + else if ( send == Group3Spin->SpinBox_DY ) { + vx = Group3Spin->SpinBox_DX->value(); vy = newValue; - vz = Group3Spin->SpinBox_DZ->GetValue(); + vz = Group3Spin->SpinBox_DZ->value(); } - else if ( send == Group3Spin->SpinBox_DZ) - { - vx = Group3Spin->SpinBox_DX->GetValue(); - vy = Group3Spin->SpinBox_DY->GetValue(); + else if ( send == Group3Spin->SpinBox_DZ ) { + vx = Group3Spin->SpinBox_DX->value(); + vy = Group3Spin->SpinBox_DY->value(); vz = newValue; } - else if ( send == Group4Spin->SpinBox_DX) - { + else if ( send == Group4Spin->SpinBox_DX ) { vx = newValue; - vy = Group4Spin->SpinBox_DY->GetValue(); - vz = Group4Spin->SpinBox_DZ->GetValue(); - vs = Group4Spin->SpinBox_DS->GetValue(); + vy = Group4Spin->SpinBox_DY->value(); + vz = Group4Spin->SpinBox_DZ->value(); + vs = Group4Spin->SpinBox_DS->value(); } - else if ( send == Group4Spin->SpinBox_DY) - { - vx = Group4Spin->SpinBox_DX->GetValue(); + else if ( send == Group4Spin->SpinBox_DY ) { + vx = Group4Spin->SpinBox_DX->value(); vy = newValue; - vz = Group4Spin->SpinBox_DZ->GetValue(); - vs = Group4Spin->SpinBox_DS->GetValue(); + vz = Group4Spin->SpinBox_DZ->value(); + vs = Group4Spin->SpinBox_DS->value(); } - else if ( send == Group4Spin->SpinBox_DZ) - { - vx = Group4Spin->SpinBox_DX->GetValue(); - vy = Group4Spin->SpinBox_DY->GetValue(); + else if ( send == Group4Spin->SpinBox_DZ ) { + vx = Group4Spin->SpinBox_DX->value(); + vy = Group4Spin->SpinBox_DY->value(); vz = newValue; - vs = Group4Spin->SpinBox_DS->GetValue(); + vs = Group4Spin->SpinBox_DS->value(); } - else if ( send == Group4Spin->SpinBox_DS) - { - vx = Group4Spin->SpinBox_DX->GetValue(); - vy = Group4Spin->SpinBox_DY->GetValue(); - vz = Group4Spin->SpinBox_DZ->GetValue(); + else if ( send == Group4Spin->SpinBox_DS ) { + vx = Group4Spin->SpinBox_DX->value(); + vy = Group4Spin->SpinBox_DY->value(); + vz = Group4Spin->SpinBox_DZ->value(); vs = newValue; } - if ( myConstructorId == 0 ) - { // SEGMENT - if ( mySketchType == PT_ABS) - { + if ( myConstructorId == 0 ) { // SEGMENT + if ( mySketchType == PT_ABS ) { myX = vx; myY = vy; } - else if ( mySketchType == PT_RELATIVE) - { + else if ( mySketchType == PT_RELATIVE ) { myDX = vx; myDY = vy; } - else if ( mySketchType == DIR_ANGLE_LENGTH) - { + else if ( mySketchType == DIR_ANGLE_LENGTH ) { myAngle = vx; myLength = vy; } - else if ( mySketchType == DIR_ANGLE_X) - { + else if ( mySketchType == DIR_ANGLE_X ) { myAngle = vx; myX = vy; } - else if ( mySketchType == DIR_ANGLE_Y) - { + else if ( mySketchType == DIR_ANGLE_Y ) { myAngle = vx; myY = vy; } - else if ( mySketchType == DIR_PER_LENGTH) - { + else if ( mySketchType == DIR_PER_LENGTH ) { myLength = vx; } - else if ( mySketchType == DIR_PER_X) - { + else if ( mySketchType == DIR_PER_X ) { myX = vx; } - else if ( mySketchType == DIR_PER_Y) - { + else if ( mySketchType == DIR_PER_Y ) { myY = vx; } - else if ( mySketchType == DIR_TAN_LENGTH) - { + else if ( mySketchType == DIR_TAN_LENGTH ) { myLength = vx; } - else if ( mySketchType == DIR_TAN_X) - { + else if ( mySketchType == DIR_TAN_X ) { myX = vx; } - else if ( mySketchType == DIR_TAN_Y) - { + else if ( mySketchType == DIR_TAN_Y ) { myY = vx; } - else if ( mySketchType == DIR_DXDY_LENGTH) - { + else if ( mySketchType == DIR_DXDY_LENGTH ) { myDX = vx; myDY = vy; myLength = vz; } - else if ( mySketchType == DIR_DXDY_X) - { + else if ( mySketchType == DIR_DXDY_X ) { myDX = vx; myDY = vy; myX = vz; } - else if ( mySketchType == DIR_DXDY_Y) - { + else if ( mySketchType == DIR_DXDY_Y ) { myDX = vx; myDY = vy; myY = vz; } } - else if ( myConstructorId == 1 ) - { // ARC - if ( mySketchType == DIR_ANGLE_LENGTH) - { + else if ( myConstructorId == 1 ) { // ARC + if ( mySketchType == DIR_ANGLE_LENGTH ) { myAngle = vx; myRadius = vy; myLength = vz; } - else if ( mySketchType == DIR_PER_LENGTH) - { + else if ( mySketchType == DIR_PER_LENGTH ) { myRadius = vx; myLength = vy; } - else if ( mySketchType == DIR_TAN_LENGTH) - { + else if ( mySketchType == DIR_TAN_LENGTH ) { myRadius = vx; myLength = vy; } - else if ( mySketchType == DIR_DXDY_LENGTH) - { + else if ( mySketchType == DIR_DXDY_LENGTH ) { myDX = vx; myDY = vy; myRadius = vz; @@ -1220,7 +1086,7 @@ void EntityGUI_SketcherDlg::ValueChangedInSpinBox(double newValue) } } - GEOMBase_Helper::displayPreview(false, true, true, myLineWidth); + GEOMBase_Helper::displayPreview( false, true, true, myLineWidth ); } @@ -1232,91 +1098,76 @@ QString EntityGUI_SketcherDlg::GetNewCommand() { QString myNewCommand = ":"; if ( mySketchState == FIRST_POINT ) { - if ( mySketchType == PT_ABS || mySketchType == PT_SEL) - myNewCommand = myNewCommand + "F " + QString::number(myX) + " " + QString::number(myY); + if ( mySketchType == PT_ABS || mySketchType == PT_SEL ) + myNewCommand = myNewCommand + "F " + QString::number( myX ) + " " + QString::number( myY ); if ( mySketchType == PT_RELATIVE) - myNewCommand = myNewCommand + "F " + QString::number(myDX) + " " + QString::number(myDY); + myNewCommand = myNewCommand + "F " + QString::number( myDX ) + " " + QString::number( myDY ); return myNewCommand; } - if ( myConstructorId == 0 ) - { // SEGMENT - if ( mySketchType == PT_ABS || mySketchType == PT_SEL) - myNewCommand = myNewCommand + "TT " + QString::number(myX) + " " + QString::number(myY); + if ( myConstructorId == 0 ) { // SEGMENT + if ( mySketchType == PT_ABS || mySketchType == PT_SEL ) + myNewCommand = myNewCommand + "TT " + QString::number( myX ) + " " + QString::number( myY ); if ( mySketchType == PT_RELATIVE) - myNewCommand = myNewCommand + "T " + QString::number(myDX) + " " + QString::number(myDY); - if ( mySketchType == DIR_ANGLE_LENGTH) - { - myNewCommand = myNewCommand + "R " + QString::number(myAngle); - myNewCommand = myNewCommand + ":" + "L " + QString::number(myLength); + myNewCommand = myNewCommand + "T " + QString::number( myDX ) + " " + QString::number( myDY ); + if ( mySketchType == DIR_ANGLE_LENGTH ) { + myNewCommand = myNewCommand + "R " + QString::number( myAngle ); + myNewCommand = myNewCommand + ":" + "L " + QString::number( myLength ); } - if ( mySketchType == DIR_ANGLE_X) - { - myNewCommand = myNewCommand + "R " + QString::number(myAngle); - myNewCommand = myNewCommand + ":" + "IX " + QString::number(myX); + if ( mySketchType == DIR_ANGLE_X ) { + myNewCommand = myNewCommand + "R " + QString::number( myAngle ); + myNewCommand = myNewCommand + ":" + "IX " + QString::number( myX ); } - if ( mySketchType == DIR_ANGLE_Y) - { - myNewCommand = myNewCommand + "R " + QString::number(myAngle); - myNewCommand = myNewCommand + ":" + "IY " + QString::number(myY); + if ( mySketchType == DIR_ANGLE_Y ) { + myNewCommand = myNewCommand + "R " + QString::number( myAngle ); + myNewCommand = myNewCommand + ":" + "IY " + QString::number( myY ); } - if ( mySketchType == DIR_PER_LENGTH) - { - myNewCommand = myNewCommand + "R " + QString::number(90.0); - myNewCommand = myNewCommand + ":" + "L " + QString::number(myLength); + if ( mySketchType == DIR_PER_LENGTH ) { + myNewCommand = myNewCommand + "R " + QString::number( 90.0 ); + myNewCommand = myNewCommand + ":" + "L " + QString::number( myLength ); } - if ( mySketchType == DIR_PER_X) - { - myNewCommand = myNewCommand + "R " + QString::number(90.0); - myNewCommand = myNewCommand + ":" + "IX " + QString::number(myX); + if ( mySketchType == DIR_PER_X ) { + myNewCommand = myNewCommand + "R " + QString::number( 90.0 ); + myNewCommand = myNewCommand + ":" + "IX " + QString::number( myX ); } - if ( mySketchType == DIR_PER_Y) - { - myNewCommand = myNewCommand + "R " + QString::number(90.0); - myNewCommand = myNewCommand + ":" + "IY " + QString::number(myY); + if ( mySketchType == DIR_PER_Y ) { + myNewCommand = myNewCommand + "R " + QString::number( 90.0 ); + myNewCommand = myNewCommand + ":" + "IY " + QString::number( myY ); } - if ( mySketchType == DIR_TAN_LENGTH) - myNewCommand = myNewCommand + "L " + QString::number(myLength); - if ( mySketchType == DIR_TAN_X) - myNewCommand = myNewCommand + "IX " + QString::number(myX); + if ( mySketchType == DIR_TAN_LENGTH ) + myNewCommand = myNewCommand + "L " + QString::number( myLength ); + if ( mySketchType == DIR_TAN_X ) + myNewCommand = myNewCommand + "IX " + QString::number( myX ); if ( mySketchType == DIR_TAN_Y) myNewCommand = myNewCommand + "IY " + QString::number(myY); - if ( mySketchType == DIR_DXDY_LENGTH) - { - myNewCommand = myNewCommand + "D " + QString::number(myDX) + " " + QString::number(myDY); - myNewCommand = myNewCommand + ":" + "L " + QString::number(myLength); + if ( mySketchType == DIR_DXDY_LENGTH ) { + myNewCommand = myNewCommand + "D " + QString::number( myDX ) + " " + QString::number( myDY ); + myNewCommand = myNewCommand + ":" + "L " + QString::number( myLength ); } - if ( mySketchType == DIR_DXDY_X) - { - myNewCommand = myNewCommand + "D " + QString::number(myDX) + " " + QString::number(myDY); - myNewCommand = myNewCommand + ":" + "IX " + QString::number(myX); + if ( mySketchType == DIR_DXDY_X ) { + myNewCommand = myNewCommand + "D " + QString::number( myDX ) + " " + QString::number( myDY ); + myNewCommand = myNewCommand + ":" + "IX " + QString::number( myX ); } - if ( mySketchType == DIR_DXDY_Y) - { - myNewCommand = myNewCommand + "D " + QString::number(myDX) + " " + QString::number(myDY); - myNewCommand = myNewCommand + ":" + "IY " + QString::number(myY); + if ( mySketchType == DIR_DXDY_Y ) { + myNewCommand = myNewCommand + "D " + QString::number( myDX ) + " " + QString::number( myDY ); + myNewCommand = myNewCommand + ":" + "IY " + QString::number( myY ); } } - else if ( myConstructorId == 1 ) - { // ARC - if ( mySketchType == DIR_ANGLE_LENGTH) - { - myNewCommand = myNewCommand + "R " + QString::number(myAngle); - myNewCommand = myNewCommand + ":" + "C " + QString::number(myRadius) + " " + QString::number(myLength); + else if ( myConstructorId == 1 ) { // ARC + if ( mySketchType == DIR_ANGLE_LENGTH ) { + myNewCommand = myNewCommand + "R " + QString::number( myAngle ); + myNewCommand = myNewCommand + ":" + "C " + QString::number( myRadius ) + " " + QString::number( myLength ); } - if ( mySketchType == DIR_PER_LENGTH) - { - myNewCommand = myNewCommand + "R " + QString::number(90.0); - myNewCommand = myNewCommand + ":" + "C " + QString::number(myRadius) + " " + QString::number(myLength); + if ( mySketchType == DIR_PER_LENGTH ) { + myNewCommand = myNewCommand + "R " + QString::number( 90.0 ); + myNewCommand = myNewCommand + ":" + "C " + QString::number( myRadius ) + " " + QString::number( myLength ); } - if ( mySketchType == DIR_TAN_LENGTH) - { - myNewCommand = myNewCommand + "C " + QString::number(myRadius) + " " + QString::number(myLength); + if ( mySketchType == DIR_TAN_LENGTH ) { + myNewCommand = myNewCommand + "C " + QString::number( myRadius ) + " " + QString::number( myLength ); } - if ( mySketchType == DIR_DXDY_LENGTH) - { - myNewCommand = myNewCommand + "D " + QString::number(myDX) + " " + QString::number(myDY); - myNewCommand = myNewCommand + ":" + "C " + QString::number(myRadius) + " " + QString::number(myLength); + if ( mySketchType == DIR_DXDY_LENGTH ) { + myNewCommand = myNewCommand + "D " + QString::number( myDX ) + " " + QString::number( myDY ); + myNewCommand = myNewCommand + ":" + "C " + QString::number( myRadius ) + " " + QString::number( myLength ); } } return myNewCommand; @@ -1346,7 +1197,7 @@ bool EntityGUI_SketcherDlg::isValid( QString& msg ) //================================================================================= bool EntityGUI_SketcherDlg::execute( ObjectList& objects ) { - if(mySketchState == FIRST_POINT) { + if ( mySketchState == FIRST_POINT ) { myLastX2 = myX; myLastY2 = myY; } @@ -1356,17 +1207,17 @@ bool EntityGUI_SketcherDlg::execute( ObjectList& objects ) //Last Shape QString Command1 = myCommand.join( "" ); - Sketcher_Profile aProfile1 (Command1.toAscii()); - if(aProfile1.IsDone()) + Sketcher_Profile aProfile1( Command1.toAscii() ); + if( aProfile1.IsDone() ) myShape1 = aProfile1.GetShape(); //Current Shape QString Command2 = Command1 + GetNewCommand(); - Sketcher_Profile aProfile2 (Command2.toAscii()); - if(aProfile2.IsDone()) + Sketcher_Profile aProfile2( Command2.toAscii() ); + if ( aProfile2.IsDone() ) myShape2 = aProfile2.GetShape(); - if(myShape2.IsNull()) { + if ( myShape2.IsNull() ) { //the current point is the same as the last one myLastX2 = myLastX1; myLastY2 = myLastY1; @@ -1374,48 +1225,48 @@ bool EntityGUI_SketcherDlg::execute( ObjectList& objects ) else { TopoDS_Vertex V1, V2; gp_Pnt pt; - if(myShape1.ShapeType() == TopAbs_VERTEX) { + if ( myShape1.ShapeType() == TopAbs_VERTEX ) { //the last shape is the first point - pt = BRep_Tool::Pnt(TopoDS::Vertex(myShape1)); + pt = BRep_Tool::Pnt( TopoDS::Vertex( myShape1 ) ); myLastX1 = pt.X(); myLastY1 = pt.Y(); } else { - TopExp::Vertices(TopoDS::Wire(myShape1), V1, V2); - pt = BRep_Tool::Pnt(V2); + TopExp::Vertices( TopoDS::Wire( myShape1 ), V1, V2 ); + pt = BRep_Tool::Pnt( V2 ); myLastX1 = pt.X(); myLastY1 = pt.Y(); } - TopExp::Vertices(TopoDS::Wire(myShape2), V1, V2); - pt = BRep_Tool::Pnt(V2); + TopExp::Vertices( TopoDS::Wire( myShape2 ), V1, V2 ); + pt = BRep_Tool::Pnt( V2 ); myLastX2 = pt.X(); myLastY2 = pt.Y(); } } QString cmd; - if( ( mySketchState != FIRST_POINT && - myLastX1 == myLastX2 && myLastY1 == myLastY2 ) || myIsAllAdded ) { + if ( ( mySketchState != FIRST_POINT && + myLastX1 == myLastX2 && myLastY1 == myLastY2 ) || myIsAllAdded ) { cmd = myCommand.join( "" ); if ( ::qobject_cast( Group1Sel->gridLayout->parent() )->isVisible() ) { - Group1Sel->buttonApply->setEnabled(false); + Group1Sel->buttonApply->setEnabled( false ); //Group1Sel->buttonApply->setFocus(); } if ( Group1Spin->isVisible() ) { - Group1Spin->buttonApply->setEnabled(false); + Group1Spin->buttonApply->setEnabled( false ); //Group1Spin->buttonApply->setFocus(); } if ( Group2Spin->isVisible() ) { - Group2Spin->buttonApply->setEnabled(false); + Group2Spin->buttonApply->setEnabled( false ); //Group2Spin->buttonApply->setFocus(); } if ( Group3Spin->isVisible() ) { - Group3Spin->buttonApply->setEnabled(false); + Group3Spin->buttonApply->setEnabled( false ); //Group3Spin->buttonApply->setFocus(); } if ( Group4Spin->isVisible() ) { - Group4Spin->buttonApply->setEnabled(false); + Group4Spin->buttonApply->setEnabled( false ); //Group4Spin->buttonApply->setFocus(); } } @@ -1423,30 +1274,30 @@ bool EntityGUI_SketcherDlg::execute( ObjectList& objects ) cmd = myCommand.join( "" ) + GetNewCommand(); if ( ::qobject_cast( Group1Sel->gridLayout->parent() )->isVisible() ) { - Group1Sel->buttonApply->setEnabled(true); + Group1Sel->buttonApply->setEnabled( true ); //Group1Sel->buttonApply->setFocus(); } if ( Group1Spin->isVisible() ) { - Group1Spin->buttonApply->setEnabled(true); + Group1Spin->buttonApply->setEnabled( true ); //Group1Spin->buttonApply->setFocus(); } if ( Group2Spin->isVisible() ) { - Group2Spin->buttonApply->setEnabled(true); + Group2Spin->buttonApply->setEnabled( true ); //Group2Spin->buttonApply->setFocus(); } if ( Group3Spin->isVisible() ) { - Group3Spin->buttonApply->setEnabled(true); + Group3Spin->buttonApply->setEnabled( true ); //Group3Spin->buttonApply->setFocus(); } if ( Group4Spin->isVisible() ) { - Group4Spin->buttonApply->setEnabled(true); + Group4Spin->buttonApply->setEnabled( true ); //Group4Spin->buttonApply->setFocus(); } } gp_Ax3 myWPlane = myGeometryGUI->GetWorkingPlane(); GEOM::ListOfDouble_var WPlane = new GEOM::ListOfDouble; - WPlane->length(9); + WPlane->length( 9 ); WPlane[0] = myWPlane.Location().X(); WPlane[1] = myWPlane.Location().Y(); WPlane[2] = myWPlane.Location().Z(); @@ -1526,26 +1377,23 @@ bool EntityGUI_SketcherDlg::createShapes( GEOM::GEOM_Object_ptr theObject, aShape.ShapeType() != TopAbs_WIRE && aShape.ShapeType() != TopAbs_VERTEX ) return false; - if ( ::qobject_cast( Group1Sel->gridLayout->parent() )->isVisible() && !Group1Sel->buttonApply->isEnabled() || + if ( Group1Sel->isVisible() && !Group1Sel->buttonApply->isEnabled() || Group1Spin->isVisible() && !Group1Spin->buttonApply->isEnabled() || Group2Spin->isVisible() && !Group2Spin->buttonApply->isEnabled() || Group3Spin->isVisible() && !Group3Spin->buttonApply->isEnabled() || - Group4Spin->isVisible() && !Group4Spin->buttonApply->isEnabled() ) - { + Group4Spin->isVisible() && !Group4Spin->buttonApply->isEnabled() ) { theApplyedWire = aShape; return true; } BRepBuilderAPI_MakeWire aBuilder; TopExp_Explorer anExp( aShape, TopAbs_EDGE ); - while( 1 ) - { + while ( 1 ) { TopoDS_Shape anEdge = anExp.Current(); anExp.Next(); if ( anExp.More() ) // i.e. non-last edge aBuilder.Add( TopoDS::Edge( anEdge ) ); - else - { + else { theLastSegment = anEdge; break; } @@ -1567,9 +1415,17 @@ void EntityGUI_SketcherDlg::keyPressEvent( QKeyEvent* e ) if ( e->isAccepted() ) return; - if ( e->key() == Qt::Key_F1 ) - { - e->accept(); - ClickOnHelp(); - } + if ( e->key() == Qt::Key_F1 ) { + e->accept(); + ClickOnHelp(); + } +} + +void EntityGUI_SketcherDlg::initSpinBox( QDoubleSpinBox* spinBox, + double min, double max, + double step, int decimals ) +{ + spinBox->setRange( min, max ); + spinBox->setSingleStep( step ); + spinBox->setDecimals( decimals ); } diff --git a/src/EntityGUI/EntityGUI_SketcherDlg.h b/src/EntityGUI/EntityGUI_SketcherDlg.h index 60db0a59b..44eb81815 100644 --- a/src/EntityGUI/EntityGUI_SketcherDlg.h +++ b/src/EntityGUI/EntityGUI_SketcherDlg.h @@ -1,152 +1,163 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI_SketcherDlg.h +// Author : Damien COQUERET, Open CASCADE S.A.S. // -// -// File : EntityGUI_SketcherDlg.h -// Author : Damine COQUERET -// Module : GEOM #ifndef ENTITYGUI_SKETCHERDLG_H #define ENTITYGUI_SKETCHERDLG_H -#include "GEOM_EntityGUI.hxx" - -#include "GEOMBase_Helper.h" +#include -#include "EntityGUI_Skeleton_QTD.h" -#include "EntityGUI_Point_QTD.h" -#include "EntityGUI_Dir1_QTD.h" -#include "EntityGUI_Dir2_QTD.h" -#include "EntityGUI_1Sel_QTD.h" +#include +class QLineEdit; +class QDoubleSpinBox; +class EntityGUI_1Sel; class EntityGUI_1Spin; class EntityGUI_2Spin; class EntityGUI_3Spin; class EntityGUI_4Spin; - +class EntityGUI_Point; +class EntityGUI_Dir1; +class EntityGUI_Dir2; +class EntityGUI_Skeleton; class GeometryGUI; +#ifndef COORD_MIN +# define COORD_MIN -1e+15 +# define COORD_MAX +1e+15 +# define MAX_NUMBER 100000 +# define DBL_DIGITS_DISPLAY 16 +#endif // COORD_MIN + //================================================================================= // class : EntityGUI_Dlg // purpose : //================================================================================= -class GEOM_ENTITYGUI_EXPORT EntityGUI_SketcherDlg : public QDialog, public Ui::EntityGUI_Skeleton_QTD, public GEOMBase_Helper +class EntityGUI_SketcherDlg : public QDialog, GEOMBase_Helper { - Q_OBJECT + Q_OBJECT public: - EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent = 0, - const char* name = 0, bool modal = FALSE, Qt::WindowFlags fl = 0, - const double lineWidth = 2.); - ~EntityGUI_SketcherDlg(); - - bool eventFilter (QObject* object, QEvent* event); + EntityGUI_SketcherDlg( GeometryGUI*, QWidget* = 0, bool = false, Qt::WindowFlags = 0, + const double = 2. ); + ~EntityGUI_SketcherDlg(); protected: - // redefined from GEOMBase_Helper - virtual GEOM::GEOM_IOperations_ptr createOperation(); - virtual bool isValid( QString& ); - virtual bool execute( ObjectList& objects ); - - void closeEvent( QCloseEvent* e ); - void keyPressEvent( QKeyEvent* e ); - -private : - void Init(); - void enterEvent(QEvent* e); - void InitClick(); - void setEnabledUndo(bool value); - void setEnabledRedo(bool value); - - QString GetNewCommand(); - - int myConstructorId; - int myConstructorDirId; - int mySketchType; - int mySketchState; - - bool myIsAllAdded; - - QLineEdit* myEditCurrentArgument; /* Current LineEdit */ - - QStringList myCommand; - QStringList myUndoCommand; - - Standard_Real myX, myY, myDX, myDY; - Standard_Real myLength, myAngle, myRadius; - Standard_Real myLastX1, myLastY1; - Standard_Real myLastX2, myLastY2; - - Ui::EntityGUI_Point_QTD* GroupPt; - Ui::EntityGUI_Dir1_QTD* GroupD1; - Ui::EntityGUI_Dir2_QTD* GroupD2; - - Ui::EntityGUI_1Sel_QTD* Group1Sel; - EntityGUI_1Spin* Group1Spin; - EntityGUI_2Spin* Group2Spin; - EntityGUI_3Spin* Group3Spin; - EntityGUI_4Spin* Group4Spin; - - GeometryGUI* myGeometryGUI; - - QString myHelpFileName; - - enum SketchState {FIRST_POINT, NEXT_POINT}; - - enum SketchType {PT_ABS, PT_RELATIVE, PT_SEL, - DIR_ANGLE_LENGTH, DIR_ANGLE_X, DIR_ANGLE_Y, - DIR_PER_LENGTH, DIR_PER_X, DIR_PER_Y, - DIR_TAN_LENGTH, DIR_TAN_X, DIR_TAN_Y, - DIR_DXDY_LENGTH, DIR_DXDY_X, DIR_DXDY_Y}; - - double myLineWidth; - virtual void displayPreview ( GEOM::GEOM_Object_ptr obj, - const bool append = false, - const bool activate = false, - const bool update = true, - const double lineWidth = -1 ); - - bool createShapes( GEOM::GEOM_Object_ptr theObject, - TopoDS_Shape& theApplyedWire, - TopoDS_Shape& theLastSegment ); - + void initSpinBox( QDoubleSpinBox*, + double, double, double = 0.1, + int = 3 ); + + // redefined from GEOMBase_Helper + virtual GEOM::GEOM_IOperations_ptr createOperation(); + virtual bool isValid( QString& ); + virtual bool execute( ObjectList& ); + + void closeEvent( QCloseEvent* ); + void keyPressEvent( QKeyEvent* ); + +private: + void Init(); + void enterEvent( QEvent* ); + void InitClick(); + void setEnabledUndo( bool ); + void setEnabledRedo( bool ); + + QString GetNewCommand(); + + virtual void displayPreview( GEOM::GEOM_Object_ptr, + const bool = false, + const bool = false, + const bool = true, + const double = -1 ); + + bool createShapes( GEOM::GEOM_Object_ptr, + TopoDS_Shape&, + TopoDS_Shape& ); + +private: + int myConstructorId; + int myConstructorDirId; + int mySketchType; + int mySketchState; + + bool myIsAllAdded; + + QLineEdit* myEditCurrentArgument; /* Current LineEdit */ + + QStringList myCommand; + QStringList myUndoCommand; + + Standard_Real myX, myY, myDX, myDY; + Standard_Real myLength, myAngle, myRadius; + Standard_Real myLastX1, myLastY1; + Standard_Real myLastX2, myLastY2; + + EntityGUI_Skeleton* MainWidget; + + EntityGUI_Point* GroupPt; + EntityGUI_Dir1* GroupD1; + EntityGUI_Dir2* GroupD2; + + EntityGUI_1Sel* Group1Sel; + EntityGUI_1Spin* Group1Spin; + EntityGUI_2Spin* Group2Spin; + EntityGUI_3Spin* Group3Spin; + EntityGUI_4Spin* Group4Spin; + + GeometryGUI* myGeometryGUI; + + QString myHelpFileName; + + double myLineWidth; + +private: + enum SketchState { FIRST_POINT, NEXT_POINT }; + + enum SketchType { PT_ABS, PT_RELATIVE, PT_SEL, + DIR_ANGLE_LENGTH, DIR_ANGLE_X, DIR_ANGLE_Y, + DIR_PER_LENGTH, DIR_PER_X, DIR_PER_Y, + DIR_TAN_LENGTH, DIR_TAN_X, DIR_TAN_Y, + DIR_DXDY_LENGTH, DIR_DXDY_X, DIR_DXDY_Y }; + private slots: - void ClickOnEnd(); - void ClickOnCancel(); - bool ClickOnApply(); - void ClickOnUndo(); - void ClickOnRedo(); - void ClickOnHelp(); - void LineEditReturnPressed(); - void SelectionIntoArgument(); - void SetEditCurrentArgument(); - void DeactivateActiveDialog(); - void ActivateThisDialog(); - void TypeClicked(int constructorId); - void DestClicked(int constructorId); - void PointClicked(int constructorId); - void Dir1Clicked(int constructorId); - void Dir2Clicked(int constructorId); - void ValueChangedInSpinBox(double newValue); + void ClickOnEnd(); + void ClickOnCancel(); + bool ClickOnApply(); + void ClickOnUndo(); + void ClickOnRedo(); + void ClickOnHelp(); + void LineEditReturnPressed(); + void SelectionIntoArgument(); + void SetEditCurrentArgument(); + void DeactivateActiveDialog(); + void ActivateThisDialog(); + void TypeClicked( int ); + void DestClicked( int ); + void PointClicked( int ); + void Dir1Clicked( int ); + void Dir2Clicked( int ); + void ValueChangedInSpinBox( double ); }; #endif // ENTITYGUI_SKETCHERDLG_H diff --git a/src/EntityGUI/EntityGUI_SubShapeDlg.cxx b/src/EntityGUI/EntityGUI_SubShapeDlg.cxx index f5eac405f..b5aec3f7a 100644 --- a/src/EntityGUI/EntityGUI_SubShapeDlg.cxx +++ b/src/EntityGUI/EntityGUI_SubShapeDlg.cxx @@ -1,44 +1,42 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI_SubShapeDlg.cxx +// Author : Lucien PIGNOLONI, Open CASCADE S.A.S. // -// -// File : EntityGUI_SubShapeDlg.cxx -// Author : Lucien PIGNOLONI -// Module : GEOM -// $Header$ #include "EntityGUI_SubShapeDlg.h" -#include "GeometryGUI.h" -#include "GEOMBase.h" +#include +#include +#include -#include "SUIT_Desktop.h" -#include "SUIT_ResourceMgr.h" -#include "SUIT_Session.h" -#include "SUIT_ViewManager.h" -#include "SUIT_ViewWindow.h" -#include "OCCViewer_ViewModel.h" -#include "SalomeApp_Application.h" -#include "LightApp_SelectionMgr.h" +#include +#include +#include +#include +#include +#include +#include +#include #include #include @@ -54,39 +52,38 @@ // The dialog will by default be modeless, unless you set 'modal' to // TRUE to construct a modal dialog. //================================================================================= -EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidget* parent, - const char* name, bool modal, Qt::WindowFlags fl) - :GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, fl) +EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg( GeometryGUI* theGeometryGUI, QWidget* parent, + bool modal, Qt::WindowFlags fl ) + : GEOMBase_Skeleton( theGeometryGUI, parent, modal, fl ) { - QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SUBSHAPE"))); - QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT"))); + QPixmap image0( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_SUBSHAPE" ) ) ); + QPixmap image1( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) ); - setWindowTitle(tr("GEOM_SUBSHAPE_TITLE")); + setWindowTitle( tr( "GEOM_SUBSHAPE_TITLE" ) ); /***************************************************************/ - GroupConstructors->setTitle(tr("GEOM_SUB_SHAPE")); - RadioButton1->setIcon(image0); - RadioButton2->setAttribute( Qt::WA_DeleteOnClose ); - RadioButton2->close(); - RadioButton3->setAttribute( Qt::WA_DeleteOnClose ); - RadioButton3->close(); - - GroupPoints = new Ui::DlgRef_1Sel1Check1List_QTD(); - QWidget* aGroupPointsWidget = new QWidget(this); - GroupPoints->setupUi(aGroupPointsWidget); - aGroupPointsWidget->setObjectName("GroupPoints"); - - GroupPoints->GroupBox1->setTitle(tr("GEOM_ARGUMENTS")); - GroupPoints->TextLabel1->setText(tr("GEOM_MAIN_OBJECT")); - GroupPoints->TextLabel2->setText(tr("GEOM_SUBSHAPE_TYPE")); - GroupPoints->CheckButton1->setText(tr("GEOM_SUBSHAPE_SELECT")); - GroupPoints->PushButton1->setIcon(image1); + mainFrame()->GroupConstructors->setTitle( tr( "GEOM_SUB_SHAPE" ) ); + mainFrame()->RadioButton1->setIcon( image0 ); + mainFrame()->RadioButton2->setAttribute( Qt::WA_DeleteOnClose ); + mainFrame()->RadioButton2->close(); + mainFrame()->RadioButton3->setAttribute( Qt::WA_DeleteOnClose ); + mainFrame()->RadioButton3->close(); + + GroupPoints = new DlgRef_1Sel1Check1List( centralWidget() ); + + GroupPoints->GroupBox1->setTitle( tr( "GEOM_ARGUMENTS" ) ); + GroupPoints->TextLabel1->setText( tr( "GEOM_MAIN_OBJECT" ) ); + GroupPoints->TextLabel2->setText( tr( "GEOM_SUBSHAPE_TYPE" ) ); + GroupPoints->CheckButton1->setText( tr( "GEOM_SUBSHAPE_SELECT" ) ); + GroupPoints->PushButton1->setIcon( image1 ); GroupPoints->LineEdit1->setReadOnly( true ); - gridLayout1->addWidget(aGroupPointsWidget, 1, 0); + QVBoxLayout* layout = new QVBoxLayout( centralWidget() ); + layout->setMargin( 0 ); layout->setSpacing( 6 ); + layout->addWidget( GroupPoints ); /***************************************************************/ - setHelpFileName("explode.htm"); + setHelpFileName( "explode.htm" ); Init(); } @@ -114,34 +111,34 @@ void EntityGUI_SubShapeDlg::Init() myWithShape = true; /* type for sub shape selection */ - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Compound"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Compsolid"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Solid"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Shell"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Face"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Wire"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Edge"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Vertex"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Shape"); - - if (SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()->getType() - != OCCViewer_Viewer::Type()) - GroupPoints->CheckButton1->setEnabled(false); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Compound" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Compsolid" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Solid" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Shell" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Face" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Wire" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Edge" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Vertex" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Shape" ); + + if ( SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()->getType() + != OCCViewer_Viewer::Type() ) + GroupPoints->CheckButton1->setEnabled( false ); /* signals and slots connections */ - connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog())); + connect( myGeomGUI, SIGNAL( SignalDeactivateActiveDialog() ), this, SLOT( DeactivateActiveDialog() ) ); - connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk())); - connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply())); + connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) ); + connect( buttonApply(), SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); - connect(GroupPoints->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument())); - connect(GroupPoints->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed())); + connect( GroupPoints->PushButton1, SIGNAL( clicked() ), this, SLOT( SetEditCurrentArgument() ) ); + connect( GroupPoints->LineEdit1, SIGNAL( returnPressed() ), this, SLOT( LineEditReturnPressed() ) ); - connect(GroupPoints->ComboBox1, SIGNAL(activated(int)), this, SLOT(ComboTextChanged())); - connect(GroupPoints->CheckButton1, SIGNAL(stateChanged(int)), this, SLOT(SubShapeToggled())); + connect( GroupPoints->ComboBox1, SIGNAL( activated( int ) ), this, SLOT( ComboTextChanged() ) ); + connect( GroupPoints->CheckButton1, SIGNAL( stateChanged( int ) ), this, SLOT( SubShapeToggled() ) ); - connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), - SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ; + connect( ( (SalomeApp_Application*)( SUIT_Session::session()->activeApplication() ) )->selectionMgr(), + SIGNAL( currentSelectionChanged( )), this, SLOT( SelectionIntoArgument() ) ); updateButtonState(); @@ -166,19 +163,19 @@ void EntityGUI_SubShapeDlg::ClickOnOk() //================================================================================= bool EntityGUI_SubShapeDlg::ClickOnApply() { - SUIT_Session::session()->activeApplication()->putInfo(tr("")); + SUIT_Session::session()->activeApplication()->putInfo( "" ); /* Explode all sub shapes */ - if( isAllSubShapes() ) { + if ( isAllSubShapes() ) { /* More than 30 subshapes : ask confirmation */ - unsigned int nb = NumberOfSubShapes(myShape, shapeType()); - if(nb > 30) { - const QString caption = tr("GEOM_CONFIRM"); - const QString text = tr("GEOM_CONFIRM_INFO").arg(nb); - const QString button0 = tr("GEOM_BUT_EXPLODE"); - const QString button1 = tr("GEOM_BUT_CANCEL"); - - if(QMessageBox::warning(this, caption, text, button0, button1) != 0) + unsigned int nb = NumberOfSubShapes( myShape, shapeType() ); + if ( nb > 30 ) { + const QString caption = tr( "GEOM_CONFIRM" ); + const QString text = tr( "GEOM_CONFIRM_INFO" ).arg( nb ); + const QString button0 = tr( "GEOM_BUT_EXPLODE" ); + const QString button1 = tr( "GEOM_BUT_CANCEL" ); + + if ( QMessageBox::warning( this, caption, text, button0, button1 ) != 0 ) return false; /* aborted */ } } @@ -207,8 +204,7 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument() TopoDS_Shape S; Handle(SALOME_InteractiveObject) IO = firstIObject(); - if ( !IO->hasEntry() ) - { + if ( !IO->hasEntry() ) { SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_SHAPE_IN_STUDY" ) ); updateButtonState(); return; @@ -216,8 +212,7 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument() if ( !GEOMBase::GetTopoFromSelection( selectedIO(), S ) || S.IsNull() || - S.ShapeType() == TopAbs_VERTEX ) - { + S.ShapeType() == TopAbs_VERTEX ) { updateButtonState(); return; } @@ -225,8 +220,7 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument() Standard_Boolean testResult; myObject = GEOMBase::ConvertIOinGEOMObject( IO, testResult ); - if ( !testResult || myObject->_is_nil() ) - { + if ( !testResult || myObject->_is_nil() ) { updateButtonState(); return; } @@ -245,27 +239,22 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument() // Solving PAL5590 if ( myShape.ShapeType() == TopAbs_COMPOUND ) { unsigned int nb = NumberOfSubShapes(myShape, TopAbs_COMPOUND); - if (nb > 0) + if ( nb > 0 ) i++; } - while ( i <= myShape.ShapeType()) - { + while ( i <= myShape.ShapeType() ) { GroupPoints->ComboBox1->removeItem( 0 ); i++; } - if ( myShape.ShapeType() == TopAbs_COMPOUND ) - { - if ( myWithShape == false ) - { + if ( myShape.ShapeType() == TopAbs_COMPOUND ) { + if ( myWithShape == false ) { GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Shape" ); myWithShape = true; } } - else - { - if ( myWithShape == true ) - { + else { + if ( myWithShape == true ) { GroupPoints->ComboBox1->removeItem( GroupPoints->ComboBox1->count() - 1 ); myWithShape = false; } @@ -275,21 +264,17 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument() if ( myWithShape ) count1 = count1 - 1; - if ( SelectedShapeType > myShape.ShapeType() ) - { - if ( SelectedShapeType == 8 ) - { - if ( myShape.ShapeType() != TopAbs_COMPOUND ) - { + if ( SelectedShapeType > myShape.ShapeType() ) { + if ( SelectedShapeType == 8 ) { + if ( myShape.ShapeType() != TopAbs_COMPOUND ) { GroupPoints->ComboBox1->setCurrentIndex( 0 ); ComboTextChanged(); } } else - GroupPoints->ComboBox1->setCurrentIndex(count1 - count + SelectedShapeType); + GroupPoints->ComboBox1->setCurrentIndex( count1 - count + SelectedShapeType ); } - else - { + else { GroupPoints->ComboBox1->setCurrentIndex( 0 ); ComboTextChanged(); } @@ -307,7 +292,7 @@ void EntityGUI_SubShapeDlg::SetEditCurrentArgument() GroupPoints->LineEdit1->setFocus(); myEditCurrentArgument = GroupPoints->LineEdit1; - GroupPoints->CheckButton1->setChecked( FALSE ); + GroupPoints->CheckButton1->setChecked( false ); SubShapeToggled(); SelectionIntoArgument(); } @@ -320,7 +305,7 @@ void EntityGUI_SubShapeDlg::SetEditCurrentArgument() void EntityGUI_SubShapeDlg::LineEditReturnPressed() { QLineEdit* send = (QLineEdit*)sender(); - if(send == GroupPoints->LineEdit1) + if ( send == GroupPoints->LineEdit1 ) SetEditCurrentArgument(); else return; @@ -335,7 +320,7 @@ void EntityGUI_SubShapeDlg::LineEditReturnPressed() //================================================================================= void EntityGUI_SubShapeDlg::DeactivateActiveDialog() { - if (GroupConstructors->isEnabled()) { + if ( mainFrame()->GroupConstructors->isEnabled() ) { GEOMBase_Skeleton::DeactivateActiveDialog(); } } @@ -348,8 +333,8 @@ void EntityGUI_SubShapeDlg::DeactivateActiveDialog() void EntityGUI_SubShapeDlg::ActivateThisDialog() { GEOMBase_Skeleton::ActivateThisDialog(); - connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), - SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ; + connect( ( (SalomeApp_Application*)( SUIT_Session::session()->activeApplication( ) ) )->selectionMgr(), + SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) ) ; SubShapeToggled(); updateButtonState(); } @@ -359,9 +344,9 @@ void EntityGUI_SubShapeDlg::ActivateThisDialog() // function : enterEvent() // purpose : //================================================================================= -void EntityGUI_SubShapeDlg::enterEvent(QEvent* e) +void EntityGUI_SubShapeDlg::enterEvent( QEvent* ) { - if (!GroupConstructors->isEnabled()) + if ( !mainFrame()->GroupConstructors->isEnabled() ) ActivateThisDialog(); } @@ -373,7 +358,7 @@ void EntityGUI_SubShapeDlg::ResetStateOfDialog() { myObject = GEOM::GEOM_Object::_nil(); myShape.Nullify(); - myEditCurrentArgument->setText(""); + myEditCurrentArgument->setText( "" ); int SelectedShapeType = GroupPoints->ComboBox1->currentIndex(); int count = GroupPoints->ComboBox1->count(); @@ -382,15 +367,15 @@ void EntityGUI_SubShapeDlg::ResetStateOfDialog() /* type for sub shape selection */ GroupPoints->ComboBox1->clear(); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Compound"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Compsolid"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Solid"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Shell"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Face"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Wire"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Edge"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Vertex"); - GroupPoints->ComboBox1->insertItem(GroupPoints->ComboBox1->count(), "Shape"); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Compound" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Compsolid" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Solid" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Shell" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Face" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Wire" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Edge" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Vertex" ); + GroupPoints->ComboBox1->insertItem( GroupPoints->ComboBox1->count(), "Shape" ); myWithShape = true; @@ -431,32 +416,33 @@ void EntityGUI_SubShapeDlg::ComboTextChanged() // function : NumberOfSubShapes() // purpose : //================================================================================= -unsigned int EntityGUI_SubShapeDlg::NumberOfSubShapes (const TopoDS_Shape& S, - const int shapeType) const +unsigned int EntityGUI_SubShapeDlg::NumberOfSubShapes( const TopoDS_Shape& S, + const int shapeType ) const { - if (S.IsNull()) + if ( S.IsNull() ) return 0; unsigned int index = 0; TopTools_MapOfShape M; - if (S.ShapeType() == TopAbs_COMPOUND && - (TopAbs_ShapeEnum(shapeType) == TopAbs_SHAPE || - TopAbs_ShapeEnum(shapeType) == TopAbs_COMPSOLID || - TopAbs_ShapeEnum(shapeType) == TopAbs_COMPOUND)) { - TopoDS_Iterator It (S, Standard_True, Standard_True); - for (; It.More(); It.Next()) { - if (M.Add(It.Value())) { - if (TopAbs_ShapeEnum(shapeType) == TopAbs_SHAPE || - TopAbs_ShapeEnum(shapeType) == It.Value().ShapeType()) { + if ( S.ShapeType() == TopAbs_COMPOUND && + ( TopAbs_ShapeEnum(shapeType) == TopAbs_SHAPE || + TopAbs_ShapeEnum(shapeType) == TopAbs_COMPSOLID || + TopAbs_ShapeEnum(shapeType) == TopAbs_COMPOUND ) ) { + TopoDS_Iterator It( S, Standard_True, Standard_True ); + for ( ; It.More(); It.Next() ) { + if ( M.Add( It.Value() ) ) { + if ( TopAbs_ShapeEnum( shapeType ) == TopAbs_SHAPE || + TopAbs_ShapeEnum( shapeType ) == It.Value().ShapeType() ) { index++; } } } - } else { - TopExp_Explorer Exp (S, TopAbs_ShapeEnum(shapeType)); - for (; Exp.More(); Exp.Next()) { - if (M.Add(Exp.Current())) { + } + else { + TopExp_Explorer Exp ( S, TopAbs_ShapeEnum( shapeType ) ); + for ( ; Exp.More(); Exp.Next() ) { + if ( M.Add( Exp.Current() ) ) { index++; } } @@ -474,11 +460,11 @@ void EntityGUI_SubShapeDlg::updateButtonState() { if ( SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()->getType() != OCCViewer_Viewer::Type() || myObject->_is_nil() || shapeType() == TopAbs_SHAPE || shapeType() == TopAbs_COMPOUND ) { - GroupPoints->CheckButton1->setChecked( FALSE ); - GroupPoints->CheckButton1->setEnabled( FALSE ); + GroupPoints->CheckButton1->setChecked( false ); + GroupPoints->CheckButton1->setEnabled( false ); } else - GroupPoints->CheckButton1->setEnabled( TRUE ); + GroupPoints->CheckButton1->setEnabled( true ); } //================================================================================= @@ -498,13 +484,13 @@ int EntityGUI_SubShapeDlg::shapeType() const { int type = GroupPoints->ComboBox1->currentIndex(); - if (myObject->_is_nil()) + if ( myObject->_is_nil() ) return type; // Solving PAL5590 type += myShape.ShapeType() + 1; - if (myShape.ShapeType() == TopAbs_COMPOUND && - NumberOfSubShapes(myShape, TopAbs_COMPOUND) > 0) { + if ( myShape.ShapeType() == TopAbs_COMPOUND && + NumberOfSubShapes( myShape, TopAbs_COMPOUND ) > 0 ) { type--; } @@ -537,7 +523,7 @@ bool EntityGUI_SubShapeDlg::isValid( QString& msg ) if ( aResult && !anObj->_is_nil() ) { TColStd_IndexedMapOfInteger aMapIndex; - ((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr()->GetIndexes( firstIObject(), aMapIndex ); + ( (SalomeApp_Application*)( SUIT_Session::session()->activeApplication() ) )->selectionMgr()->GetIndexes( firstIObject(), aMapIndex ); isOk = aMapIndex.Extent() > 0; if ( !isOk ) msg += tr( "NO_SUBSHAPES_SELECTED" ); @@ -561,8 +547,7 @@ bool EntityGUI_SubShapeDlg::execute( ObjectList& objects ) // Throw away sub-shapes not selected by user if not in preview mode // and manual selection is active - if ( !isAllSubShapes() ) - { + if ( !isAllSubShapes() ) { if ( IObjectCount() == 1 ) { Standard_Boolean aResult = Standard_False; GEOM::GEOM_Object_var anObj = @@ -570,7 +555,7 @@ bool EntityGUI_SubShapeDlg::execute( ObjectList& objects ) if ( aResult && !anObj->_is_nil() ) { TColStd_IndexedMapOfInteger aMapIndex; - ((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr()->GetIndexes( firstIObject(), aMapIndex ); + ( (SalomeApp_Application*)( SUIT_Session::session()->activeApplication() ) )->selectionMgr()->GetIndexes( firstIObject(), aMapIndex ); GEOM::GEOM_ILocalOperations_var aLocOp = getGeomEngine()->GetILocalOperations( getStudyId() ); diff --git a/src/EntityGUI/EntityGUI_SubShapeDlg.h b/src/EntityGUI/EntityGUI_SubShapeDlg.h index d99635118..27d71f38e 100644 --- a/src/EntityGUI/EntityGUI_SubShapeDlg.h +++ b/src/EntityGUI/EntityGUI_SubShapeDlg.h @@ -1,91 +1,86 @@ -// GEOM GEOMGUI : GUI for Geometry component +// GEOM GEOMGUI : GUI for Geometry component // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// Copyright (C) 2003 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. // -// 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 // +// File : EntityGUI_SubShapeDlg.h +// Author : Lucien PIGNOLONI, Open CASCADE S.A.S. // -// -// File : EntityGUI_SubShapeDlg.h -// Author : Lucien PIGNOLONI -// Module : GEOM -#ifndef DIALOGBOX_SUBSHAPE_H -#define DIALOGBOX_SUBSHAPE_H +#ifndef ENTITYGUI_SUBSHAPEDLG_H +#define ENTITYGUI_SUBSHAPEDLG_H -#include "GEOM_EntityGUI.hxx" +#include -#include "GEOMBase_Skeleton.h" -#include "DlgRef_1Sel1Check1List_QTD.h" +class DlgRef_1Sel1Check1List; //================================================================================= // class : EntityGUI_SubShapeDlg // purpose : //================================================================================= -class GEOM_ENTITYGUI_EXPORT EntityGUI_SubShapeDlg : public GEOMBase_Skeleton +class EntityGUI_SubShapeDlg : public GEOMBase_Skeleton { - Q_OBJECT + Q_OBJECT public: - EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, - const char* name = 0, bool modal = FALSE, Qt::WindowFlags fl = 0); - ~EntityGUI_SubShapeDlg(); + EntityGUI_SubShapeDlg( GeometryGUI*, QWidget* = 0, bool = false, Qt::WindowFlags = 0 ); + ~EntityGUI_SubShapeDlg(); protected: - // redefined from GEOMBase_Helper - virtual GEOM::GEOM_IOperations_ptr createOperation(); - virtual bool isValid( QString& ); - virtual bool execute( ObjectList& objects ); - virtual GEOM::GEOM_Object_ptr getFather( GEOM::GEOM_Object_ptr theObj ); - virtual const char* getNewObjectName() const; + // redefined from GEOMBase_Helper + virtual GEOM::GEOM_IOperations_ptr createOperation(); + virtual bool isValid( QString& ); + virtual bool execute( ObjectList& ); + virtual GEOM::GEOM_Object_ptr getFather( GEOM::GEOM_Object_ptr ); + virtual const char* getNewObjectName() const; private slots: - void ClickOnOk(); - bool ClickOnApply(); - void ActivateThisDialog(); - void DeactivateActiveDialog(); - void LineEditReturnPressed(); - void SelectionIntoArgument(); - void SetEditCurrentArgument(); - void SubShapeToggled(); - void ComboTextChanged(); + void ClickOnOk(); + bool ClickOnApply(); + void ActivateThisDialog(); + void DeactivateActiveDialog(); + void LineEditReturnPressed(); + void SelectionIntoArgument(); + void SetEditCurrentArgument(); + void SubShapeToggled(); + void ComboTextChanged(); -private : - void Init(); - void enterEvent( QEvent* e ); +private: + void Init(); + void enterEvent( QEvent* ); - void ResetStateOfDialog(); - unsigned int NumberOfSubShapes (const TopoDS_Shape& S, - const int shapeType) const; + void ResetStateOfDialog(); + unsigned int NumberOfSubShapes( const TopoDS_Shape&, + const int ) const; - void updateButtonState(); - bool isAllSubShapes() const; - int shapeType() const; + void updateButtonState(); + bool isAllSubShapes() const; + int shapeType() const; private: - - TopoDS_Shape myShape; - GEOM::GEOM_Object_var myObject; - - bool myWithShape; - - Ui::DlgRef_1Sel1Check1List_QTD* GroupPoints; - ObjectList myResult; + TopoDS_Shape myShape; + GEOM::GEOM_Object_var myObject; + + bool myWithShape; + + DlgRef_1Sel1Check1List* GroupPoints; + ObjectList myResult; }; -#endif // DIALOGBOX_SUBSHAPE_H +#endif // ENTITYGUI_SUBSHAPEDLG_H diff --git a/src/EntityGUI/EntityGUI_Widgets.cxx b/src/EntityGUI/EntityGUI_Widgets.cxx new file mode 100644 index 000000000..86d64e1ca --- /dev/null +++ b/src/EntityGUI/EntityGUI_Widgets.cxx @@ -0,0 +1,172 @@ +// Copyright (C) 2003 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 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 +// +// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org +// +// File : EntityGUI_Widgets.cxx +// Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com) +// + +#include "EntityGUI_Widgets.h" +#include + +////////////////////////////////////////// +// EntityGUI_1Sel +////////////////////////////////////////// + +EntityGUI_1Sel::EntityGUI_1Sel( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); +} + +EntityGUI_1Sel::~EntityGUI_1Sel() +{ +} + +////////////////////////////////////////// +// EntityGUI_1Spin +////////////////////////////////////////// + +EntityGUI_1Spin::EntityGUI_1Spin( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); +} + +EntityGUI_1Spin::~EntityGUI_1Spin() +{ +} + +////////////////////////////////////////// +// EntityGUI_2Spin +////////////////////////////////////////// + +EntityGUI_2Spin::EntityGUI_2Spin( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); +} + +EntityGUI_2Spin::~EntityGUI_2Spin() +{ +} + +////////////////////////////////////////// +// EntityGUI_3Spin +////////////////////////////////////////// + +EntityGUI_3Spin::EntityGUI_3Spin( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); +} + +EntityGUI_3Spin::~EntityGUI_3Spin() +{ +} + +////////////////////////////////////////// +// EntityGUI_4Spin +////////////////////////////////////////// + +EntityGUI_4Spin::EntityGUI_4Spin( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); +} + +EntityGUI_4Spin::~EntityGUI_4Spin() +{ +} + +////////////////////////////////////////// +// EntityGUI_Dir1 +////////////////////////////////////////// + +EntityGUI_Dir1::EntityGUI_Dir1( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); + + ButtonGroup = new QButtonGroup( this ); + ButtonGroup->addButton( RB_Dir11, 2 ); + ButtonGroup->addButton( RB_Dir12, 0 ); + ButtonGroup->addButton( RB_Dir13, 1 ); + ButtonGroup->addButton( RB_Dir14, 3 ); +} + +EntityGUI_Dir1::~EntityGUI_Dir1() +{ +} + +////////////////////////////////////////// +// EntityGUI_Dir2 +////////////////////////////////////////// + +EntityGUI_Dir2::EntityGUI_Dir2( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); + + ButtonGroup = new QButtonGroup( this ); + ButtonGroup->addButton( RB_Dir21, 2 ); + ButtonGroup->addButton( RB_Dir22, 0 ); + ButtonGroup->addButton( RB_Dir23, 1 ); +} + +EntityGUI_Dir2::~EntityGUI_Dir2() +{ +} + +////////////////////////////////////////// +// EntityGUI_Point +////////////////////////////////////////// + +EntityGUI_Point::EntityGUI_Point( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); + + ButtonGroup = new QButtonGroup( this ); + ButtonGroup->addButton( RB_Point1, 1 ); + ButtonGroup->addButton( RB_Point2, 0 ); + ButtonGroup->addButton( RB_Point3, 2 ); +} + +EntityGUI_Point::~EntityGUI_Point() +{ +} + +////////////////////////////////////////// +// EntityGUI_Skeleton +////////////////////////////////////////// + +EntityGUI_Skeleton::EntityGUI_Skeleton( QWidget* parent, Qt::WindowFlags f ) +: QWidget( parent, f ) +{ + setupUi( this ); + + ButtonGroup = new QButtonGroup( this ); + ButtonGroup->addButton( RadioButton1, 0 ); + ButtonGroup->addButton( RadioButton2, 1 ); +} + +EntityGUI_Skeleton::~EntityGUI_Skeleton() +{ +} + diff --git a/src/EntityGUI/EntityGUI_Widgets.h b/src/EntityGUI/EntityGUI_Widgets.h new file mode 100644 index 000000000..fc27bd9e7 --- /dev/null +++ b/src/EntityGUI/EntityGUI_Widgets.h @@ -0,0 +1,181 @@ +// Copyright (C) 2003 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 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 +// +// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org +// +// File : EntityGUI_Widgets.h +// Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com) +// + +#ifndef ENTITYGUI_WIDGETS_H +#define ENTITYGUI_WIDGETS_H + +////////////////////////////////////////// +// EntityGUI_1Sel +////////////////////////////////////////// + +#include "ui_EntityGUI_1Sel_QTD.h" + +class EntityGUI_1Sel : public QWidget, + public Ui::EntityGUI_1Sel_QTD +{ + Q_OBJECT + +public: + EntityGUI_1Sel( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_1Sel(); +}; + +////////////////////////////////////////// +// EntityGUI_1Spin +////////////////////////////////////////// + +#include "ui_EntityGUI_1Spin_QTD.h" + +class EntityGUI_1Spin : public QWidget, + public Ui::EntityGUI_1Spin_QTD +{ + Q_OBJECT + +public: + EntityGUI_1Spin( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_1Spin(); +}; + +////////////////////////////////////////// +// EntityGUI_2Spin +////////////////////////////////////////// + +#include "ui_EntityGUI_2Spin_QTD.h" + +class EntityGUI_2Spin : public QWidget, + public Ui::EntityGUI_2Spin_QTD +{ + Q_OBJECT + +public: + EntityGUI_2Spin( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_2Spin(); +}; + +////////////////////////////////////////// +// EntityGUI_3Spin +////////////////////////////////////////// + +#include "ui_EntityGUI_3Spin_QTD.h" + +class EntityGUI_3Spin : public QWidget, + public Ui::EntityGUI_3Spin_QTD +{ + Q_OBJECT + +public: + EntityGUI_3Spin( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_3Spin(); +}; + +////////////////////////////////////////// +// EntityGUI_4Spin +////////////////////////////////////////// + +#include "ui_EntityGUI_4Spin_QTD.h" + +class EntityGUI_4Spin : public QWidget, + public Ui::EntityGUI_4Spin_QTD +{ + Q_OBJECT + +public: + EntityGUI_4Spin( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_4Spin(); +}; + +////////////////////////////////////////// +// EntityGUI_Dir1 +////////////////////////////////////////// + +#include "ui_EntityGUI_Dir1_QTD.h" + +class EntityGUI_Dir1 : public QWidget, + public Ui::EntityGUI_Dir1_QTD +{ + Q_OBJECT + +public: + EntityGUI_Dir1( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_Dir1(); + + QButtonGroup* ButtonGroup; +}; + +////////////////////////////////////////// +// EntityGUI_Dir2 +////////////////////////////////////////// + +#include "ui_EntityGUI_Dir2_QTD.h" + +class EntityGUI_Dir2 : public QWidget, + public Ui::EntityGUI_Dir2_QTD +{ + Q_OBJECT + +public: + EntityGUI_Dir2( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_Dir2(); + + QButtonGroup* ButtonGroup; +}; + +////////////////////////////////////////// +// EntityGUI_Point +////////////////////////////////////////// + +#include "ui_EntityGUI_Point_QTD.h" + +class EntityGUI_Point : public QWidget, + public Ui::EntityGUI_Point_QTD +{ + Q_OBJECT + +public: + EntityGUI_Point( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_Point(); + + QButtonGroup* ButtonGroup; +}; + +////////////////////////////////////////// +// EntityGUI_Skeleton +////////////////////////////////////////// + +#include "ui_EntityGUI_Skeleton_QTD.h" + +class QButtonGroup; + +class EntityGUI_Skeleton : public QWidget, + public Ui::EntityGUI_Skeleton_QTD +{ + Q_OBJECT + +public: + EntityGUI_Skeleton( QWidget* = 0, Qt::WindowFlags = 0 ); + ~EntityGUI_Skeleton(); + + QButtonGroup* ButtonGroup; +}; + +#endif // ENTITYGUI_WIDGETS_H diff --git a/src/EntityGUI/GEOM_EntityGUI.hxx b/src/EntityGUI/GEOM_EntityGUI.hxx deleted file mode 100755 index 2a42f3423..000000000 --- a/src/EntityGUI/GEOM_EntityGUI.hxx +++ /dev/null @@ -1,47 +0,0 @@ -// Copyright (C) 2003 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 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 -// -// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org -// -// -// -// File : GEOM_EntityGUI.hxx -// Author : Alexander A. BORODIN -// Module : GEOM - -#ifndef _GEOM_EntityGUI_HXX_ -#define _GEOM_EntityGUI_HXX_ - -#ifdef WNT - #if defined ENTITYGUI_EXPORTS - #if defined WIN32 - #define GEOM_ENTITYGUI_EXPORT __declspec( dllexport ) - #else - #define GEOM_ENTITYGUI_EXPORT - #endif - #else - #if defined WIN32 - #define GEOM_ENTITYGUI_EXPORT __declspec( dllimport ) - #else - #define GEOM_ENTITYGUI_EXPORT - #endif - #endif -#else - #define GEOM_ENTITYGUI_EXPORT -#endif - -#endif diff --git a/src/EntityGUI/Makefile.am b/src/EntityGUI/Makefile.am index 4964aed39..5fb23fd5d 100644 --- a/src/EntityGUI/Makefile.am +++ b/src/EntityGUI/Makefile.am @@ -1,31 +1,28 @@ -# GEOM ENTITYGUI : +# GEOM ENTITYGUI : # -# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# Copyright (C) 2003 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. # -# 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 # +# File : Makefile.am +# Author : Alexander BORODIN, Open CASCADE S.A.S. (alexander.borodin@opencascade.com) +# Package : EntityGUI # -# -# File : Makefile.in -# Author : Damien COQUERET (OCC) -# Modified by : Alexander BORODIN (OCN) - autotools usage -# Module : GEOM -# $Header: include $(top_srcdir)/adm_local/unix/make_common_starter.am @@ -33,60 +30,73 @@ include $(top_srcdir)/adm_local/unix/make_common_starter.am lib_LTLIBRARIES = libEntityGUI.la # header files -salomeinclude_HEADERS = \ - GEOM_EntityGUI.hxx +salomeinclude_HEADERS = -dist_libEntityGUI_la_SOURCES = EntityGUI.cxx \ - EntityGUI_1Spin.cxx \ - EntityGUI_2Spin.cxx \ - EntityGUI_3Spin.cxx \ - EntityGUI_4Spin.cxx \ - EntityGUI_SketcherDlg.cxx \ +dist_libEntityGUI_la_SOURCES = \ + EntityGUI.h \ + EntityGUI_Widgets.h \ + EntityGUI_SketcherDlg.h \ + EntityGUI_SubShapeDlg.h \ + \ + EntityGUI.cxx \ + EntityGUI_Widgets.cxx \ + EntityGUI_SketcherDlg.cxx \ EntityGUI_SubShapeDlg.cxx -MOC_FILES = \ - EntityGUI_1Spin_moc.cxx \ - EntityGUI_2Spin_moc.cxx \ - EntityGUI_3Spin_moc.cxx \ - EntityGUI_4Spin_moc.cxx \ - EntityGUI_SketcherDlg_moc.cxx \ +MOC_FILES = \ + EntityGUI_Widgets_moc.cxx \ + EntityGUI_SketcherDlg_moc.cxx \ EntityGUI_SubShapeDlg_moc.cxx -nodist_libEntityGUI_la_SOURCES= \ +nodist_libEntityGUI_la_SOURCES = \ $(MOC_FILES) +UIC_FILES = \ + ui_EntityGUI_1Sel_QTD.h \ + ui_EntityGUI_1Spin_QTD.h \ + ui_EntityGUI_2Spin_QTD.h \ + ui_EntityGUI_3Spin_QTD.h \ + ui_EntityGUI_4Spin_QTD.h \ + ui_EntityGUI_Dir1_QTD.h \ + ui_EntityGUI_Dir2_QTD.h \ + ui_EntityGUI_Point_QTD.h \ + ui_EntityGUI_Skeleton_QTD.h + +BUILT_SOURCES = $(UIC_FILES) + # LIB_CLIENT_IDL = SALOME_Exception.idl SALOME_GenericObj.idl SALOME_Component.idl # LIB_SERVER_IDL = # additionnal information to compil and link file -libEntityGUI_la_CPPFLAGS = \ - $(QT_INCLUDES) \ - $(CAS_CPPFLAGS) \ - $(VTK_INCLUDES) \ - $(PYTHON_INCLUDES) \ - $(BOOST_CPPFLAGS) \ - $(KERNEL_CXXFLAGS) \ - $(GUI_CXXFLAGS) \ - $(CORBA_CXXFLAGS) \ - $(CORBA_INCLUDES) \ - -I$(srcdir)/../GEOMGUI \ - -I$(srcdir)/../DlgRef \ - -I$(srcdir)/../GEOMBase \ - -I$(srcdir)/../OBJECT \ - -I$(srcdir)/../GEOMClient \ - -I$(srcdir)/../GEOMImpl \ - -I$(srcdir)/../GEOMFiltersSelection \ - -I$(srcdir)/../SKETCHER \ - -I$(top_builddir)/idl \ +libEntityGUI_la_CPPFLAGS = \ + $(QT_INCLUDES) \ + $(CAS_CPPFLAGS) \ + $(VTK_INCLUDES) \ + $(PYTHON_INCLUDES) \ + $(BOOST_CPPFLAGS) \ + $(KERNEL_CXXFLAGS) \ + $(GUI_CXXFLAGS) \ + $(CORBA_CXXFLAGS) \ + $(CORBA_INCLUDES) \ + -I$(srcdir)/../GEOMGUI \ + -I$(srcdir)/../DlgRef \ + -I$(srcdir)/../GEOMBase \ + -I$(srcdir)/../OBJECT \ + -I$(srcdir)/../GEOMClient \ + -I$(srcdir)/../GEOMImpl \ + -I$(srcdir)/../GEOMFiltersSelection \ + -I$(srcdir)/../SKETCHER \ + -I$(top_builddir)/src/DlgRef \ + -I$(top_builddir)/idl \ -I$(top_builddir)/salome_adm/unix libEntityGUI_la_LDFLAGS = \ - ../GEOMFiltersSelection/libGEOMFiltersSelection.la \ - ../GEOMBase/libGEOMBase.la \ - ../SKETCHER/libGEOMSketcher.la \ - ../GEOMGUI/libGEOM.la \ - $(QT_MT_LIBS) \ + ../GEOMFiltersSelection/libGEOMFiltersSelection.la \ + ../GEOMBase/libGEOMBase.la \ + ../SKETCHER/libGEOMSketcher.la \ + ../GEOMGUI/libGEOM.la \ + $(QT_MT_LIBS) \ $(CAS_TKTopAlgo) -lTKernel diff --git a/src/EntityGUI/UIFiles/EntityGUI_1Sel_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_1Sel_QTD.ui deleted file mode 100644 index 9611e596c..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_1Sel_QTD.ui +++ /dev/null @@ -1,182 +0,0 @@ - - - - - EntityGUI_1Sel_QTD - - - - 0 - 0 - 329 - 112 - - - - EntityGUI_1Sel_QTD - - - - 0 - - - 6 - - - - - Values - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - - 0 - 163 - - - - Expanding - - - Vertical - - - - - - - Create - - - - - - - 0 - - - 6 - - - - - Redo - - - - - - - Undo - - - - - - - - - - - 0 - - - 6 - - - - - - 0 - 0 - 0 - 0 - - - - TL1 - - - false - - - - - - - - 0 - 180 - - - - Expanding - - - Vertical - - - - - - - - 0 - 0 - 0 - 0 - - - - - - - - - - - - 3 - 0 - 0 - 0 - - - - - - - - - - - - - - - qPixmapFromMimeSource - diff --git a/src/EntityGUI/UIFiles/EntityGUI_1Spin_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_1Spin_QTD.ui deleted file mode 100644 index 8985fa8b0..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_1Spin_QTD.ui +++ /dev/null @@ -1,167 +0,0 @@ - - - - - EntityGUI_1Spin_QTD - - - - 0 - 0 - 255 - 112 - - - - EntityGUI_1Spin_QTD - - - - 0 - - - 6 - - - - - Values - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - - 0 - 0 - 0 - 0 - - - - TL1 - - - false - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 82 - - - - Expanding - - - Vertical - - - - - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - Redo - - - - - - - Undo - - - - - - - - - Create - - - - - - - - 0 - 40 - - - - Expanding - - - Vertical - - - - - - - - - - - - - - qPixmapFromMimeSource - diff --git a/src/EntityGUI/UIFiles/EntityGUI_2Spin_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_2Spin_QTD.ui deleted file mode 100644 index ec014f170..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_2Spin_QTD.ui +++ /dev/null @@ -1,197 +0,0 @@ - - - - - EntityGUI_2Spin_QTD - - - - 0 - 0 - 255 - 112 - - - - EntityGUI_2Spin_QTD - - - - 0 - - - 6 - - - - - Values - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - - 0 - 0 - 0 - 0 - - - - TL2 - - - false - - - - - - - - 0 - 0 - 0 - 0 - - - - TL1 - - - false - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 82 - - - - Expanding - - - Vertical - - - - - - - - - 0 - - - 6 - - - - - - 0 - 51 - - - - Expanding - - - Vertical - - - - - - - 0 - - - 6 - - - - - Undo - - - - - - - Redo - - - - - - - - - Create - - - - - - - - - - - - - - qPixmapFromMimeSource - diff --git a/src/EntityGUI/UIFiles/EntityGUI_3Spin_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_3Spin_QTD.ui deleted file mode 100644 index 08b867ef9..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_3Spin_QTD.ui +++ /dev/null @@ -1,227 +0,0 @@ - - - - - EntityGUI_3Spin_QTD - - - - 0 - 0 - 255 - 125 - - - - EntityGUI_3Spin_QTD - - - - 0 - - - 6 - - - - - Values - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - Create - - - - - - - - 0 - 121 - - - - Expanding - - - Vertical - - - - - - - 0 - - - 6 - - - - - Undo - - - - - - - Redo - - - - - - - - - - - 0 - - - 6 - - - - - - 0 - 0 - 0 - 0 - - - - TL2 - - - false - - - - - - - - 0 - 0 - 0 - 0 - - - - TL1 - - - false - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 0 - 0 - 0 - - - - TL3 - - - false - - - - - - - - 0 - 82 - - - - Expanding - - - Vertical - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - - - - - - - qPixmapFromMimeSource - diff --git a/src/EntityGUI/UIFiles/EntityGUI_4Spin_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_4Spin_QTD.ui deleted file mode 100644 index d6b3453be..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_4Spin_QTD.ui +++ /dev/null @@ -1,257 +0,0 @@ - - - - - EntityGUI_4Spin_QTD - - - - 0 - 0 - 255 - 154 - - - - EntityGUI_4Spin_QTD - - - - 0 - - - 6 - - - - - Values - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - 0 - - - 6 - - - - - Redo - - - - - - - Undo - - - - - - - - - - 0 - 45 - - - - Expanding - - - Vertical - - - - - - - Create - - - - - - - - - 0 - - - 6 - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 0 - 0 - 0 - - - - TL2 - - - false - - - - - - - - 0 - 70 - - - - Expanding - - - Vertical - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 0 - 0 - 0 - - - - TL3 - - - false - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - - 0 - 0 - 0 - 0 - - - - TL1 - - - false - - - - - - - - 0 - 0 - 0 - 0 - - - - TL4 - - - false - - - - - - - - - - - - - - qPixmapFromMimeSource - diff --git a/src/EntityGUI/UIFiles/EntityGUI_Dir1_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_Dir1_QTD.ui deleted file mode 100644 index 17e1dca50..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_Dir1_QTD.ui +++ /dev/null @@ -1,96 +0,0 @@ - - - - - EntityGUI_Dir1_QTD - - - - 0 - 0 - 131 - 123 - - - - EntityGUI_Dir1_QTD - - - - 0 - - - 6 - - - - - - 7 - 0 - 0 - 0 - - - - Direction - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - Perpendicular - - - - - - - Tangent - - - - - - - Angle - - - - - - - VX-VY - - - - - - - - - - - - qPixmapFromMimeSource - - RB_Dir11 - RB_Dir12 - RB_Dir13 - RB_Dir14 - - diff --git a/src/EntityGUI/UIFiles/EntityGUI_Dir2_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_Dir2_QTD.ui deleted file mode 100644 index 8d2cd1579..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_Dir2_QTD.ui +++ /dev/null @@ -1,104 +0,0 @@ - - - - - EntityGUI_Dir2_QTD - - - - 0 - 0 - 124 - 106 - - - - EntityGUI_Dir2_QTD - - - - 0 - - - 6 - - - - - - 7 - 7 - 0 - 0 - - - - Direction - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - X - - - - - - - Y - - - - - - - - 0 - 20 - - - - Expanding - - - Vertical - - - - - - - Length - - - - - - - - - - - - qPixmapFromMimeSource - - RB_Dir21 - RB_Dir22 - RB_Dir23 - - diff --git a/src/EntityGUI/UIFiles/EntityGUI_Point_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_Point_QTD.ui deleted file mode 100644 index 668d778e5..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_Point_QTD.ui +++ /dev/null @@ -1,88 +0,0 @@ - - - - - EntityGUI_Point_QTD - - - - 0 - 0 - 124 - 106 - - - - EntityGUI_Point_QTD - - - - 0 - - - 6 - - - - - - 7 - 0 - 0 - 0 - - - - Point - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - Relative - - - - - - - Absolute - - - - - - - Selection - - - - - - - - - - - - qPixmapFromMimeSource - - RB_Point1 - RB_Point2 - RB_Point3 - - diff --git a/src/EntityGUI/UIFiles/EntityGUI_Skeleton_QTD.ui b/src/EntityGUI/UIFiles/EntityGUI_Skeleton_QTD.ui deleted file mode 100644 index 6e65ff423..000000000 --- a/src/EntityGUI/UIFiles/EntityGUI_Skeleton_QTD.ui +++ /dev/null @@ -1,321 +0,0 @@ - - - - - EntityGUI_Skeleton_QTD - - - - 0 - 0 - 317 - 276 - - - - - 5 - 7 - 0 - 0 - - - - EntityGUI_Skeleton_QTD - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - - 7 - 7 - 0 - 0 - - - - - - - - - - - - 5 - 0 - 0 - 0 - - - - Element Type - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - Segment - - - - - - - Arc - - - - - - - - - - - - - 7 - 0 - 0 - 0 - - - - Destination - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - - 7 - 0 - 0 - 0 - - - - Type - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - Direction - - - - - - - Point - - - - - - - - - - - - - 7 - 7 - 0 - 0 - - - - - - - - 11 - - - 6 - - - - - - - - - 7 - 7 - 0 - 0 - - - - - - - - 11 - - - 6 - - - - - - - - - - - - - - 7 - 0 - 0 - 0 - - - - - - - - 11 - - - 6 - - - - - 0 - - - 6 - - - - - End Sketch - - - - - - - Close Sketch - - - - - - - - 91 - 0 - - - - Expanding - - - Horizontal - - - - - - - &Cancel - - - - - - - &Help - - - - - - - - - - - - - - qPixmapFromMimeSource - - RadioButton1 - RadioButton2 - RB_Dest1 - RB_Dest2 - buttonEnd - buttonClose - buttonCancel - - diff --git a/src/EntityGUI/UIFiles/ui_to_cxx b/src/EntityGUI/UIFiles/ui_to_cxx deleted file mode 100755 index 4fef1c79e..000000000 --- a/src/EntityGUI/UIFiles/ui_to_cxx +++ /dev/null @@ -1,37 +0,0 @@ -# Copyright (C) 2005 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 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 -#// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com -# -#!/bin/sh - -uic -o ../EntityGUI_Skeleton_QTD.h EntityGUI_Skeleton_QTD.ui - -uic -o ../EntityGUI_Point_QTD.h EntityGUI_Point_QTD.ui - -uic -o ../EntityGUI_Dir1_QTD.h EntityGUI_Dir1_QTD.ui - -uic -o ../EntityGUI_Dir2_QTD.h EntityGUI_Dir2_QTD.ui - -uic -o ../EntityGUI_1Spin_QTD.h EntityGUI_1Spin_QTD.ui - -uic -o ../EntityGUI_2Spin_QTD.h EntityGUI_2Spin_QTD.ui - -uic -o ../EntityGUI_3Spin_QTD.h EntityGUI_3Spin_QTD.ui - -uic -o ../EntityGUI_4Spin_QTD.h EntityGUI_4Spin_QTD.ui - -uic -o ../EntityGUI_1Sel_QTD.h EntityGUI_1Sel_QTD.ui -- 2.39.2