From ee148cc6a5a3d5de232ed20ed8c4d29058e522ac Mon Sep 17 00:00:00 2001 From: rnc Date: Mon, 5 Mar 2012 15:25:31 +0000 Subject: [PATCH] Added help page and revert some changes for a better ergonomy --- .../GEOM/input/extruded_boss_operation.doc | 8 +++++ .../gui/GEOM/input/extruded_cut_operation.doc | 8 +++++ .../GEOM/input/transformation_operations.doc | 2 ++ .../OperationGUI_ExtrudedFeatureDlg.cxx | 36 +++++++++++-------- .../OperationGUI_ExtrudedFeatureDlg.h | 2 +- 5 files changed, 41 insertions(+), 15 deletions(-) create mode 100644 doc/salome/gui/GEOM/input/extruded_boss_operation.doc create mode 100644 doc/salome/gui/GEOM/input/extruded_cut_operation.doc diff --git a/doc/salome/gui/GEOM/input/extruded_boss_operation.doc b/doc/salome/gui/GEOM/input/extruded_boss_operation.doc new file mode 100644 index 000000000..79d50f0cd --- /dev/null +++ b/doc/salome/gui/GEOM/input/extruded_boss_operation.doc @@ -0,0 +1,8 @@ +/*! + +\page extruded_boss_operation_page Extruded boss + +The "Extruded boss" operation allows you to add material to an object by extruding a profile or a face +along the normal to its plane. + +*/ diff --git a/doc/salome/gui/GEOM/input/extruded_cut_operation.doc b/doc/salome/gui/GEOM/input/extruded_cut_operation.doc new file mode 100644 index 000000000..27ae76dad --- /dev/null +++ b/doc/salome/gui/GEOM/input/extruded_cut_operation.doc @@ -0,0 +1,8 @@ +/*! + +\page extruded_cut_operation_page Extruded cut + +The "Extruded cut" operation allows you to remove material from an object by extruding a profile or a face +along the normal to its plane. + +*/ diff --git a/doc/salome/gui/GEOM/input/transformation_operations.doc b/doc/salome/gui/GEOM/input/transformation_operations.doc index ab90c5140..fedea7cfc 100644 --- a/doc/salome/gui/GEOM/input/transformation_operations.doc +++ b/doc/salome/gui/GEOM/input/transformation_operations.doc @@ -24,6 +24,8 @@ which allow to: corners of a Wire with Planar Edges.
  • Produce a \subpage fillet2d_operation_page "2D Fillet" on the corners of a Planar Face.
  • Produce a \subpage chamfer_operation_page "Chamfer" on the selected edges of an object.
  • +
  • Remove matter from an object by producing an \subpage extruded_cut_operation_page "Extruded Cut".
  • +
  • Add matter to an object by producing an \subpage extruded_boss_operation_page "Extruded Boss".
  • */ diff --git a/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.cxx b/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.cxx index e4267561f..80f6a8e53 100644 --- a/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.cxx +++ b/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.cxx @@ -75,10 +75,12 @@ OperationGUI_ExtrudedFeatureDlg::OperationGUI_ExtrudedFeatureDlg(const int theOp case OperationGUI::BOSS: image0 = QPixmap(aResMgr->loadPixmap("GEOM", tr("ICO_EXTRUDED_BOSS"))); aTitle = tr("GEOM_EXTRUDED_BOSS"); + setHelpFileName("extruded_boss_operation_page.html"); break; case OperationGUI::CUT: image0 = QPixmap( aResMgr->loadPixmap("GEOM", tr("ICO_EXTRUDED_CUT"))); aTitle = tr("GEOM_EXTRUDED_CUT"); + setHelpFileName("extruded_cut_operation_page.html"); break; } @@ -209,8 +211,8 @@ void OperationGUI_ExtrudedFeatureDlg::SetEditCurrentArgument() myGroup->PushButton2->setDown(false); myGroup->LineEdit2->setEnabled(false); - - globalSelection(); // close local selection + +// globalSelection(); // close local selection } else if (send == myGroup->PushButton2) { myEditCurrentArgument = myGroup->LineEdit2; @@ -218,9 +220,15 @@ void OperationGUI_ExtrudedFeatureDlg::SetEditCurrentArgument() myGroup->PushButton1->setDown(false); myGroup->LineEdit1->setEnabled(false); - globalSelection(); // close local selection to clear it -// localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE ); - localSelection( GEOM::GEOM_Object::_nil(), TopAbs_FACE ); +// globalSelection(); // close local selection to clear it + +// // localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE ); +// if (myObject1) +// { +// localSelection( myObject1.get(), TopAbs_FACE ); +// // localSelection( myObject1.get(), TopAbs_EDGE ); +// } +// /* localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE ); */ } // enable line edit @@ -360,7 +368,7 @@ bool OperationGUI_ExtrudedFeatureDlg::execute (ObjectList& objects) bool isProtrusion = (myOperation == OperationGUI::BOSS); // Hide the initial shape in order to see the modifications on the preview - getDisplayer()->Erase(myObject1.get(),false,false); + erase(myObject1.get(),false); GEOM::GEOM_Object_var anObj = anOper->MakeDraftPrism(myObject1.get(), myObject2.get(), myGroup->SpinBox_DX->value(), @@ -372,14 +380,14 @@ bool OperationGUI_ExtrudedFeatureDlg::execute (ObjectList& objects) return true; } -//================================================================================= -// function : addSubshapeToStudy -// purpose : virtual method to add new SubObjects if local selection -//================================================================================= -void OperationGUI_ExtrudedFeatureDlg::addSubshapesToStudy() -{ - GEOMBase::PublishSubObject( myObject2.get() ); -} +// //================================================================================= +// // function : addSubshapeToStudy +// // purpose : virtual method to add new SubObjects if local selection +// //================================================================================= +// void OperationGUI_ExtrudedFeatureDlg::addSubshapesToStudy() +// { +// GEOMBase::PublishSubObject( myObject2.get() ); +// } diff --git a/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.h b/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.h index 1cfd028bb..6a3123105 100644 --- a/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.h +++ b/src/OperationGUI/OperationGUI_ExtrudedFeatureDlg.h @@ -61,7 +61,7 @@ protected: virtual GEOM::GEOM_IOperations_ptr createOperation(); virtual bool isValid( QString& ); virtual bool execute( ObjectList& ); - virtual void addSubshapesToStudy(); +// virtual void addSubshapesToStudy(); private: void Init(); -- 2.39.2