From d08c093f57913c390f6eb26ab59a0bde4d10f0c3 Mon Sep 17 00:00:00 2001 From: eap Date: Fri, 12 Dec 2014 14:19:02 +0300 Subject: [PATCH] 0022768: [EDF] Model inspector --- doc/salome/gui/GEOM/images/inspect_object.png | Bin 0 -> 29765 bytes .../GEOM/input/inspect_object_operation.doc | 22 + .../GEOM/input/using_measurement_tools.doc | 1 + idl/GEOM_Gen.idl | 12 + src/GEOMBase/GEOMBase.cxx | 4 +- src/GEOMBase/GEOMBase.h | 2 +- src/GEOMGUI/GEOM_images.ts | 4 + src/GEOMGUI/GEOM_msg_en.ts | 43 + src/GEOMGUI/GEOM_msg_fr.ts | 43 + src/GEOMGUI/GEOM_msg_ja.ts | 43 + src/GEOMGUI/GeometryGUI.cxx | 3 + src/GEOMGUI/GeometryGUI_Operations.h | 1 + src/GEOM_I/GEOM_Object_i.cc | 42 + src/GEOM_I/GEOM_Object_i.hh | 2 + src/RepairGUI/CMakeLists.txt | 3 + src/RepairGUI/RepairGUI.cxx | 2 + src/RepairGUI/RepairGUI_InspectObjectDlg.cxx | 794 ++++++++++++++++++ src/RepairGUI/RepairGUI_InspectObjectDlg.h | 88 ++ 18 files changed, 1107 insertions(+), 2 deletions(-) create mode 100644 doc/salome/gui/GEOM/images/inspect_object.png create mode 100755 doc/salome/gui/GEOM/input/inspect_object_operation.doc create mode 100644 src/RepairGUI/RepairGUI_InspectObjectDlg.cxx create mode 100644 src/RepairGUI/RepairGUI_InspectObjectDlg.h diff --git a/doc/salome/gui/GEOM/images/inspect_object.png b/doc/salome/gui/GEOM/images/inspect_object.png new file mode 100644 index 0000000000000000000000000000000000000000..09d90d0699337e4314fb5409490731e33a5af3f9 GIT binary patch literal 29765 zcmbSy18`l@|L2R{SdDGlwi??;W4n!Q+qRv?PUEIgqsF%P_P6ujncdmh+1)cQ$>hFy z@4k2L_k7PsH{y$;6cYSrcn}DLBqJ@Z0s?_m0za0p;J^{jtjtN^51ga4whIXKDI554 z0}H3d^8^mkxJqcbikr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gT<8e>bSkic*dxH><$Gkf=qd%xY52)pX{(KIhzH!)|u@Stb~0$H%!>7 zL<7>xen$mPvRg^+@w7=;VtUBQZ6Tx^Q=040d?{fAA>kS$nn;n7JA{MtSFo(#!foND zOPt~&SZ(|t0qlPS!?o&U18KZoz)E{Z$5KpM@iCW5tRm}dYj%qv5ONqP4t=f7hz5r& zWyDH?ultAwVb4lm_0HzzQ{n>NPN$<4F8oZ1OA%ZC9$uvLo}I8~FaEQmBVKumhlAs- zZ_k@xr#l4?`J#j8D>K%f_24CFY)#A1u3f}9h_4+ZdD#m5{MKvpkLq&_4H!4Ki*f#O zr0!f7{oqN1>>dJP;YD%r*^8eGsV_!GuarE=H9bGI%y(oynWNTV;!$wnh!`P&ZN}|& h&W@gKopjO0?fc!%nTojLD?kZHw2mEmrD=8j{{SzjQF;IX literal 0 HcmV?d00001 diff --git a/doc/salome/gui/GEOM/input/inspect_object_operation.doc b/doc/salome/gui/GEOM/input/inspect_object_operation.doc new file mode 100755 index 000000000..c1a36f3ff --- /dev/null +++ b/doc/salome/gui/GEOM/input/inspect_object_operation.doc @@ -0,0 +1,22 @@ +/*! + +\page inspect_object_operation_page Inspect Object + +This operation allows browsing the contents of the selected shape. + +To Inspect Object, in the Main Menu select Repair - > Inspect Object. + +\image html inspect_object.png + +In this dialog: +- Click on the "selection" button and select an object to inspect in the Object Browser or in the viewer. +- Show/hide sub-shape(s) in the 3D viewer, by pressing “eye” icon in the first column of the tree view. +- Show/hide all sub-shapes in the 3D viewer, by pressing “eye” icon in the first column of the tree view header. +- Rename selected sub-shape by double-clicking on the item or pressing key. +- Show selected sub-shape(s) in the 3D viewer by pressing Show Selected button. +- Show selected sub-shape(s) in the 3D viewer and erase all currently shown objects by pressing Show Only Selected button. +- Hide selected sub-shape(s) from the 3D viewer by pressing Hide Selected button. +- Publish selected sub-shapes in the study, by pressing Publish Selected button. +- Close dialog box, by pressing Close button. + +*/ diff --git a/doc/salome/gui/GEOM/input/using_measurement_tools.doc b/doc/salome/gui/GEOM/input/using_measurement_tools.doc index 2672156cd..77a5ee4b3 100644 --- a/doc/salome/gui/GEOM/input/using_measurement_tools.doc +++ b/doc/salome/gui/GEOM/input/using_measurement_tools.doc @@ -18,6 +18,7 @@
  • \subpage tolerance_page "Tolerance"
  • \subpage managing_dimensions_page "Dimensions"
  • \subpage whatis_page "WhatIs"
  • +
  • \subpage inspect_object_operation_page "Inspect Object"
  • \n To check their integrity: diff --git a/idl/GEOM_Gen.idl b/idl/GEOM_Gen.idl index 6a38a71db..e9805e23d 100644 --- a/idl/GEOM_Gen.idl +++ b/idl/GEOM_Gen.idl @@ -394,6 +394,18 @@ module GEOM */ shape_type GetMaxShapeType(); + /*! + * \brief Returns a name of a sub-shape if the sub-shape is published in the study + * \param subID - sub-shape ID + * \return string - the found name or an empty string if the sub-shape does not + * exits or is not published in the study + * + * \note Only sub-shapes directly retrieved (using e.g. ExtractSubShapes() or + * via group creation) can be found. Also, as sub-shape can be published in the study + * many times, only the first found name is returned. + */ + string GetSubShapeName(in long subID); + /*! * \brief Set color of the object. * diff --git a/src/GEOMBase/GEOMBase.cxx b/src/GEOMBase/GEOMBase.cxx index 849e433af..58c8ee0d0 100644 --- a/src/GEOMBase/GEOMBase.cxx +++ b/src/GEOMBase/GEOMBase.cxx @@ -808,7 +808,7 @@ bool GEOMBase::IsShape( GEOM::GEOM_Object_ptr object ) // function : TypeName() // purpose : Get string representation for the shape type //======================================================================= -QString GEOMBase::TypeName( TopAbs_ShapeEnum type ) +QString GEOMBase::TypeName( TopAbs_ShapeEnum type, bool capitalize ) { QString name = "shape"; switch( type ) { @@ -831,6 +831,8 @@ QString GEOMBase::TypeName( TopAbs_ShapeEnum type ) default: break; } + if ( capitalize && !name.isEmpty() ) + name = name.left(1).toUpper() + name.mid(1); return name; } diff --git a/src/GEOMBase/GEOMBase.h b/src/GEOMBase/GEOMBase.h index 1a6782330..313fe0ec7 100644 --- a/src/GEOMBase/GEOMBase.h +++ b/src/GEOMBase/GEOMBase.h @@ -127,7 +127,7 @@ public : static bool IsShape( GEOM::GEOM_Object_ptr object ); /* Get string representation of shape type */ - static QString TypeName( TopAbs_ShapeEnum type ); + static QString TypeName( TopAbs_ShapeEnum type, bool capitalize = false ); /* Get study entry for the given object */ static QString GetEntry( GEOM::GEOM_Object_ptr object ); diff --git a/src/GEOMGUI/GEOM_images.ts b/src/GEOMGUI/GEOM_images.ts index 6877d9c7c..84876a3b7 100644 --- a/src/GEOMGUI/GEOM_images.ts +++ b/src/GEOMGUI/GEOM_images.ts @@ -239,6 +239,10 @@ ICON_DLG_UNION_FACES union_faces.png + + ICON_DLG_INSPECT_OBJECT + inspect_object.png + ICON_DLG_CHECKSHAPE check.png diff --git a/src/GEOMGUI/GEOM_msg_en.ts b/src/GEOMGUI/GEOM_msg_en.ts index 86e1622a7..95843a4c3 100644 --- a/src/GEOMGUI/GEOM_msg_en.ts +++ b/src/GEOMGUI/GEOM_msg_en.ts @@ -4776,6 +4776,18 @@ Please, select face, shell or solid and try again STB_UNION_FACES Union faces + + TOP_INSPECT_OBJECT + Inspect Object + + + MEN_INSPECT_OBJECT + Inspect Object + + + STB_INSPECT_OBJECT + Inspect Object + TOP_NORMALE Normal to a face @@ -7045,6 +7057,37 @@ Do you want to create new material? UnionFaces + + RepairGUI_InspectObjectDlg + + GEOM_INSPECT_OBJECT_TITLE + Inspect object + + + GEOM_INSPECT_OBJECT_MAIN_SHAPE + Main shape + + + GEOM_INSPECT_OBJECT_SHOW + Show Selected + + + GEOM_INSPECT_OBJECT_SHOW_ONLY + Show Only Selected + + + GEOM_INSPECT_OBJECT_HIDE + Hide Selected + + + GEOM_INSPECT_OBJECT_PUBLISH + Publish Selected + + + GEOM_INSPECT_OBJECT_NAME + Name + + GEOMGUI_CreationInfoWdg diff --git a/src/GEOMGUI/GEOM_msg_fr.ts b/src/GEOMGUI/GEOM_msg_fr.ts index 62edf1628..9f06bd72e 100644 --- a/src/GEOMGUI/GEOM_msg_fr.ts +++ b/src/GEOMGUI/GEOM_msg_fr.ts @@ -4712,6 +4712,18 @@ Choisissez une face, une coque ou un solide et essayez de nouveau STB_UNION_FACES Unir les faces + + TOP_INSPECT_OBJECT + Inspect Object + + + MEN_INSPECT_OBJECT + Inspect Object + + + STB_INSPECT_OBJECT + Inspect Object + TOP_NORMALE Vecteur normal à une face @@ -6973,6 +6985,37 @@ Voulez-vous en créer un nouveau ? UnirFaces + + RepairGUI_InspectObjectDlg + + GEOM_INSPECT_OBJECT_TITLE + Inspect object + + + GEOM_INSPECT_OBJECT_MAIN_SHAPE + Main shape + + + GEOM_INSPECT_OBJECT_SHOW + Show Selected + + + GEOM_INSPECT_OBJECT_SHOW_ONLY + Show Only Selected + + + GEOM_INSPECT_OBJECT_HIDE + Hide Selected + + + GEOM_INSPECT_OBJECT_PUBLISH + Publish Selected + + + GEOM_INSPECT_OBJECT_NAME + Name + + GEOMGUI_CreationInfoWdg diff --git a/src/GEOMGUI/GEOM_msg_ja.ts b/src/GEOMGUI/GEOM_msg_ja.ts index 8ef05204b..5a8b514a1 100644 --- a/src/GEOMGUI/GEOM_msg_ja.ts +++ b/src/GEOMGUI/GEOM_msg_ja.ts @@ -4703,6 +4703,18 @@ STB_UNION_FACES 連合に直面しています。 + + TOP_INSPECT_OBJECT + Inspect Object + + + MEN_INSPECT_OBJECT + Inspect Object + + + STB_INSPECT_OBJECT + Inspect Object + TOP_NORMALE フェースに垂直 @@ -6950,6 +6962,37 @@ UnionFaces + + RepairGUI_InspectObjectDlg + + GEOM_INSPECT_OBJECT_TITLE + Inspect object + + + GEOM_INSPECT_OBJECT_MAIN_SHAPE + Main shape + + + GEOM_INSPECT_OBJECT_SHOW + Show Selected + + + GEOM_INSPECT_OBJECT_SHOW_ONLY + Show Only Selected + + + GEOM_INSPECT_OBJECT_HIDE + Hide Selected + + + GEOM_INSPECT_OBJECT_PUBLISH + Publish Selected + + + GEOM_INSPECT_OBJECT_NAME + Name + + GEOMGUI_CreationInfoWdg diff --git a/src/GEOMGUI/GeometryGUI.cxx b/src/GEOMGUI/GeometryGUI.cxx index 883347659..567ecb356 100644 --- a/src/GEOMGUI/GeometryGUI.cxx +++ b/src/GEOMGUI/GeometryGUI.cxx @@ -622,6 +622,7 @@ void GeometryGUI::OnGUIEvent( int id, const QVariant& theParam ) case GEOMOp::OpRemoveExtraEdges: // MENU REPAIR - REMOVE EXTRA EDGES case GEOMOp::OpFuseEdges: // MENU REPAIR - FUSE COLLINEAR EDGES case GEOMOp::OpUnionFaces: // MENU REPAIR - UNION FACES + case GEOMOp::OpInspectObj: // MENU REPAIR - INSPECT OBJECT libName = "RepairGUI"; break; case GEOMOp::OpProperties: // MENU MEASURE - PROPERTIES @@ -1000,6 +1001,7 @@ void GeometryGUI::initialize( CAM_Application* app ) createGeomAction( GEOMOp::OpRemoveExtraEdges, "REMOVE_EXTRA_EDGES" ); createGeomAction( GEOMOp::OpFuseEdges, "FUSE_EDGES" ); createGeomAction( GEOMOp::OpUnionFaces, "UNION_FACES" ); + createGeomAction( GEOMOp::OpInspectObj, "INSPECT_OBJECT" ); createGeomAction( GEOMOp::OpPointCoordinates, "POINT_COORDS" ); createGeomAction( GEOMOp::OpProperties, "BASIC_PROPS" ); @@ -1276,6 +1278,7 @@ void GeometryGUI::initialize( CAM_Application* app ) createMenu( GEOMOp::OpGetNonBlocks, measurId, -1 ); createMenu( GEOMOp::OpCheckSelfInters, measurId, -1 ); createMenu( GEOMOp::OpFastCheckInters, measurId, -1 ); + createMenu( GEOMOp::OpInspectObj, measurId, -1 ); int toolsId = createMenu( tr( "MEN_TOOLS" ), -1, -1, 50 ); #if defined(_DEBUG_) || defined(_DEBUG) // PAL16821 diff --git a/src/GEOMGUI/GeometryGUI_Operations.h b/src/GEOMGUI/GeometryGUI_Operations.h index 8b01f7a0f..ca48c6cba 100644 --- a/src/GEOMGUI/GeometryGUI_Operations.h +++ b/src/GEOMGUI/GeometryGUI_Operations.h @@ -195,6 +195,7 @@ namespace GEOMOp { OpShowAllDimensions = 5015, // POPUP MENU - SHOW ALL DIMENSIONS OpHideAllDimensions = 5016, // POPUP MENU - HIDE ALL DIMENSIONS OpFastCheckInters = 5017, // MENU MEASURES - FAST CHECK INTERSECTIONS + OpInspectObj = 5018, // MENU MEASURES - INSPECT OBJECT // GroupGUI --------------------//-------------------------------- OpGroupCreate = 6000, // MENU GROUP - CREATE OpGroupEdit = 6001, // MENU GROUP - EDIT diff --git a/src/GEOM_I/GEOM_Object_i.cc b/src/GEOM_I/GEOM_Object_i.cc index 54e5c458d..920aa557a 100644 --- a/src/GEOM_I/GEOM_Object_i.cc +++ b/src/GEOM_I/GEOM_Object_i.cc @@ -36,6 +36,7 @@ #include #include #include +#include #include #include @@ -158,6 +159,47 @@ GEOM::shape_type GEOM_Object_i::GetMaxShapeType() return getMinMaxShapeType( _impl->GetValue(), false ); } +//================================================================================ +/*! + * GetSubShapeName + */ +//================================================================================ + +char* GEOM_Object_i::GetSubShapeName(CORBA::Long subID) +{ + CORBA::String_var name(""); + + Handle(GEOM_Function) aMainFun = _impl->GetLastFunction(); + if ( aMainFun.IsNull() ) return name._retn(); + + const TDataStd_ListOfExtendedString& aListEntries = aMainFun->GetSubShapeReferences(); + TDataStd_ListIteratorOfListOfExtendedString anIt( aListEntries ); + for (; anIt.More(); anIt.Next()) + { + TCollection_AsciiString anEntry = anIt.Value(); + Handle(GEOM_BaseObject) anObj = + GEOM_Engine::GetEngine()->GetObject( _impl->GetDocID(), anEntry.ToCString(), false ); + if ( anObj.IsNull() ) continue; + + TCollection_AsciiString aSubName = anObj->GetName(); + if ( aSubName.IsEmpty() ) continue; + + Handle(GEOM_Function) aFun = anObj->GetLastFunction(); + if ( aFun.IsNull() ) continue; + + GEOM_ISubShape ISS( aFun ); + Handle(TColStd_HArray1OfInteger) subIDs = ISS.GetIndices(); + if ( subIDs.IsNull() || subIDs->Length() != 1 ) continue; + + if ( subIDs->Value( subIDs->Lower() ) == subID ) + { + name = aSubName.ToCString(); + break; + } + } + return name._retn(); +} + //============================================================================= /*! * SetColor diff --git a/src/GEOM_I/GEOM_Object_i.hh b/src/GEOM_I/GEOM_Object_i.hh index da7f035ed..dffc72663 100644 --- a/src/GEOM_I/GEOM_Object_i.hh +++ b/src/GEOM_I/GEOM_Object_i.hh @@ -47,6 +47,8 @@ class GEOM_I_EXPORT GEOM_Object_i : public virtual POA_GEOM::GEOM_Object, public virtual GEOM::shape_type GetMaxShapeType(); + virtual char* GetSubShapeName(CORBA::Long subID); + virtual void SetColor(const SALOMEDS::Color& theColor); virtual SALOMEDS::Color GetColor(); diff --git a/src/RepairGUI/CMakeLists.txt b/src/RepairGUI/CMakeLists.txt index 9cc1ac419..9d26ede7b 100755 --- a/src/RepairGUI/CMakeLists.txt +++ b/src/RepairGUI/CMakeLists.txt @@ -83,6 +83,7 @@ SET(RepairGUI_HEADERS RepairGUI_RemoveExtraEdgesDlg.h RepairGUI_UnionFacesDlg.h RepairGUI_FuseEdgesDlg.h + RepairGUI_InspectObjectDlg.h ) # header files / to be processed by moc @@ -103,6 +104,7 @@ SET(_moc_HEADERS RepairGUI_RemoveExtraEdgesDlg.h RepairGUI_UnionFacesDlg.h RepairGUI_FuseEdgesDlg.h + RepairGUI_InspectObjectDlg.h ) # header files / uic wrappings @@ -131,6 +133,7 @@ SET(RepairGUI_SOURCES RepairGUI_RemoveExtraEdgesDlg.cxx RepairGUI_UnionFacesDlg.cxx RepairGUI_FuseEdgesDlg.cxx + RepairGUI_InspectObjectDlg.cxx ${_moc_SOURCES} ${_uic_files} ) diff --git a/src/RepairGUI/RepairGUI.cxx b/src/RepairGUI/RepairGUI.cxx index b8e95235e..f2e44d1e3 100644 --- a/src/RepairGUI/RepairGUI.cxx +++ b/src/RepairGUI/RepairGUI.cxx @@ -48,6 +48,7 @@ #include "RepairGUI_RemoveExtraEdgesDlg.h" // Method REMOVE EXTRA EDGES #include "RepairGUI_FuseEdgesDlg.h" // Method FUSE COLLINEAR EDGES #include "RepairGUI_UnionFacesDlg.h" // Method UNION FACES +#include "RepairGUI_InspectObjectDlg.h" // Method INSPECT OBJECT //======================================================================= // function : RepairGUI() @@ -97,6 +98,7 @@ bool RepairGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent ) case GEOMOp::OpRemoveExtraEdges: aDlg = new RepairGUI_RemoveExtraEdgesDlg (getGeometryGUI(), parent); break; case GEOMOp::OpFuseEdges: aDlg = new RepairGUI_FuseEdgesDlg (getGeometryGUI(), parent); break; case GEOMOp::OpUnionFaces: aDlg = new RepairGUI_UnionFacesDlg (getGeometryGUI(), parent); break; + case GEOMOp::OpInspectObj: aDlg = new RepairGUI_InspectObjectDlg (parent); break; default: app->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID)); break; diff --git a/src/RepairGUI/RepairGUI_InspectObjectDlg.cxx b/src/RepairGUI/RepairGUI_InspectObjectDlg.cxx new file mode 100644 index 000000000..d7382dd73 --- /dev/null +++ b/src/RepairGUI/RepairGUI_InspectObjectDlg.cxx @@ -0,0 +1,794 @@ +// Copyright (C) 2014 CEA/DEN, EDF R&D, OPEN CASCADE +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// 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 +// + +// internal includes +#include "RepairGUI_InspectObjectDlg.h" + +// GEOM includes +#include +#include +#include + +// GUI includes +#include +#include +#include +#include +#include + +#include + +#include +#include + +#include +#include + +// OCCT includes +#include + +// Qt includes +#include +#include +#include +#include + +//================================================================================= +// class : RepairGUI_InspectObjectDlg::TreeWidgetItem +// purpose : class for "Inspect Object" tree item creation +//================================================================================= +class RepairGUI_InspectObjectDlg::TreeWidgetItem : public QTreeWidgetItem +{ +public: + TreeWidgetItem( QTreeWidget*, const QStringList&, const TopoDS_Shape&, const Handle(SALOME_InteractiveObject)&, int = Type ); + TreeWidgetItem( QTreeWidgetItem*, const QStringList&, const TopoDS_Shape&, const QString&, int = Type ); + ~TreeWidgetItem(); + + bool isVisible(); + void setVisible( bool, QIcon& ); + + TopoDS_Shape getShape() const; + Handle(SALOME_InteractiveObject) getIO() const; + +private: + bool myIsVisible; + TopoDS_Shape myShape; + Handle(SALOME_InteractiveObject) myIO; + +}; + +RepairGUI_InspectObjectDlg::TreeWidgetItem::TreeWidgetItem( QTreeWidget* view, const QStringList &strings, const TopoDS_Shape& shape, + const Handle(SALOME_InteractiveObject)& io, int type ) +: QTreeWidgetItem( view, strings, type ), + myIsVisible( false ), + myShape( shape ), + myIO( io ) +{ +} + +RepairGUI_InspectObjectDlg::TreeWidgetItem::TreeWidgetItem( QTreeWidgetItem* parent, const QStringList &strings, + const TopoDS_Shape& shape, const QString& entry, int type ) +: QTreeWidgetItem( parent, strings, type ), + myIsVisible( false ), + myShape( shape ) +{ + myIO = new SALOME_InteractiveObject( entry.toAscii(), "GEOM", "TEMP_IO" ); + setFlags( flags() | Qt::ItemIsEditable ); +} + +RepairGUI_InspectObjectDlg::TreeWidgetItem::~TreeWidgetItem() +{ +} + +bool RepairGUI_InspectObjectDlg::TreeWidgetItem::isVisible() +{ + return myIsVisible; +} + +void RepairGUI_InspectObjectDlg::TreeWidgetItem::setVisible( bool isVisible, QIcon& icon ) +{ + myIsVisible = isVisible; + setIcon( 1, icon ); +} + +TopoDS_Shape RepairGUI_InspectObjectDlg::TreeWidgetItem::getShape() const +{ + return myShape; +} + +Handle(SALOME_InteractiveObject) RepairGUI_InspectObjectDlg::TreeWidgetItem::getIO() const +{ + return myIO; +} + +//================================================================================= +// class : RepairGUI_InspectObjectDlg::Delegate +// purpose : class for "Inspect Object" tree item editing +//================================================================================= +class RepairGUI_InspectObjectDlg::Delegate : public QItemDelegate +{ +public: + Delegate( QObject* = 0 ); + ~Delegate(); + + void setEditorData( QWidget*, const QModelIndex& ) const; + void setModelData( QWidget*, QAbstractItemModel*, const QModelIndex& ) const; + QWidget* createEditor( QWidget*, const QStyleOptionViewItem&, const QModelIndex& ) const; +}; + +RepairGUI_InspectObjectDlg::Delegate::Delegate( QObject* parent ) +: QItemDelegate( parent ) +{ +} + +RepairGUI_InspectObjectDlg::Delegate::~Delegate() +{ +} + +void RepairGUI_InspectObjectDlg::Delegate::setEditorData( QWidget* editor, + const QModelIndex& index ) const +{ + QItemDelegate::setEditorData( editor, index ); + editor->setProperty( "___name___", editor->property( "text" ) ); +} + +void RepairGUI_InspectObjectDlg::Delegate::setModelData( QWidget* editor, + QAbstractItemModel* model, + const QModelIndex& index ) const +{ + QString aNewName = editor->property( "text" ).toString(); + if ( aNewName.trimmed().isEmpty() ) + editor->setProperty( "text", editor->property( "___name___" ) ); + QItemDelegate::setModelData( editor, model, index ); +} + +QWidget* RepairGUI_InspectObjectDlg::Delegate::createEditor( QWidget* parent, + const QStyleOptionViewItem& option, + const QModelIndex& index ) const +{ + return index.column() == 1 ? 0 : QItemDelegate::createEditor( parent, option, index ); +} + +//================================================================================= +// class : RepairGUI_InspectObjectDlg() +// purpose : Constructs a RepairGUI_InspectObjectDlg which is a child of 'parent'. +//================================================================================= +RepairGUI_InspectObjectDlg::RepairGUI_InspectObjectDlg( SUIT_Desktop* parent ) +: GEOMBase_Helper( parent ), + QDialog( parent ), + myTransparency( 0.0 ), + myIsSelectAll( false ) +{ + QIcon iconSelect( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) ); + myVisible = QIcon( SUIT_Session::session()->resourceMgr()->loadPixmap( "SUIT", tr( "ICON_DATAOBJ_VISIBLE" ) ) ); + myInvisible = QIcon( SUIT_Session::session()->resourceMgr()->loadPixmap( "SUIT", tr( "ICON_DATAOBJ_INVISIBLE" ) ) ); + + setWindowTitle( tr( "GEOM_INSPECT_OBJECT_TITLE" ) ); + setAttribute( Qt::WA_DeleteOnClose ); + + myApp = dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication() ); + myViewWindow = myApp->desktop()->activeWindow(); + + QGridLayout* topLayout = new QGridLayout( this ); + topLayout->setMargin( 11 ); topLayout->setSpacing( 6 ); + + /********************** Inspected Object **********************/ + + QHBoxLayout* mainShapeLayout = new QHBoxLayout(); + + QLabel* label = new QLabel( tr( "GEOM_INSPECT_OBJECT_MAIN_SHAPE" ) ); + QPushButton* selBtn = new QPushButton(); + selBtn->setIcon( iconSelect ); + myEditMainShape = new QLineEdit(); + myEditMainShape->setReadOnly(true); + + mainShapeLayout->addWidget( label ); + mainShapeLayout->addWidget( selBtn ); + mainShapeLayout->addWidget( myEditMainShape ); + + /********************** Sub-objects tree **********************/ + + myTreeObjects = new QTreeWidget(); + myTreeObjects->setColumnCount( 2 ); + QStringList columnNames; + columnNames.append( tr( "GEOM_INSPECT_OBJECT_NAME" ) ); + columnNames.append(""); + myTreeObjects->setHeaderLabels( columnNames ); + QTreeWidgetItem* headerItem = new QTreeWidgetItem( columnNames ); + myTreeObjects->setHeaderItem( headerItem ); + myTreeObjects->header()->moveSection( 1, 0 ); + myTreeObjects->header()->setClickable( true ); + myTreeObjects->header()->setMovable( false ); + myTreeObjects->header()->setResizeMode( 1, QHeaderView::ResizeToContents ); + myTreeObjects->setSelectionMode( QAbstractItemView::ExtendedSelection ); + myTreeObjects->setEditTriggers( QAbstractItemView::DoubleClicked | QAbstractItemView::EditKeyPressed ); + // set custom item delegate + myTreeObjects->setItemDelegate( new Delegate( myTreeObjects ) ); + + /********************** Buttons **********************/ + + QVBoxLayout* buttonsLayout1 = new QVBoxLayout(); + + QPushButton* buttonShow = new QPushButton( tr( "GEOM_INSPECT_OBJECT_SHOW" ) ); + QPushButton* buttonShowOnly = new QPushButton( tr( "GEOM_INSPECT_OBJECT_SHOW_ONLY" ) ); + QPushButton* buttonHide = new QPushButton( tr( "GEOM_INSPECT_OBJECT_HIDE" ) ); + QPushButton* buttonPublish = new QPushButton( tr( "GEOM_INSPECT_OBJECT_PUBLISH" ) ); + + buttonsLayout1->addWidget( buttonShow ); + buttonsLayout1->addWidget( buttonShowOnly ); + buttonsLayout1->addWidget( buttonHide ); + buttonsLayout1->addStretch(); + buttonsLayout1->addWidget( buttonPublish ); + buttonsLayout1->addStretch(); + + QHBoxLayout* buttonsLayout2 = new QHBoxLayout(); + + QPushButton* buttonClose = new QPushButton( tr( "GEOM_BUT_CLOSE" ) ); + QPushButton* buttonHelp = new QPushButton( tr( "GEOM_BUT_HELP" ) ); + + buttonsLayout2->addWidget( buttonClose ); + buttonsLayout2->addStretch(); + buttonsLayout2->addWidget( buttonHelp ); + + topLayout->addLayout( mainShapeLayout, 0, 0 ); + topLayout->addWidget( myTreeObjects, 1, 0 ); + topLayout->addLayout( buttonsLayout1, 0, 1, 2, 1 ); + topLayout->addLayout( buttonsLayout2, 2, 0, 1, 2 ); + + // Signals and slots connections + + connect( selBtn, SIGNAL( clicked() ), this, SLOT( onEditMainShape() ) ); + + connect( myTreeObjects, SIGNAL( itemClicked( QTreeWidgetItem*, int ) ), + this, SLOT( onItemClicked( QTreeWidgetItem*, int ) ) ); + connect( myTreeObjects, SIGNAL( itemChanged( QTreeWidgetItem*, int ) ), + this, SLOT( onItemChanged( QTreeWidgetItem*, int ) ) ); + connect( myTreeObjects, SIGNAL( itemExpanded ( QTreeWidgetItem* ) ), + this, SLOT( onItemExpanded( QTreeWidgetItem* ) ) ); + connect( myTreeObjects, SIGNAL( itemSelectionChanged() ), + this, SLOT( onItemSelectionChanged() ) ); + + connect( myTreeObjects->header(), SIGNAL( sectionClicked( int ) ), this, SLOT( onHeaderClicked( int ) ) ); + + connect( buttonShow, SIGNAL( clicked() ), this, SLOT( clickOnShow() ) ); + connect( buttonShowOnly, SIGNAL( clicked() ), this, SLOT( clickOnShowOnly() ) ); + connect( buttonHide, SIGNAL( clicked() ), this, SLOT( clickOnHide() ) ); + connect( buttonPublish, SIGNAL( clicked() ), this, SLOT( clickOnPublish() ) ); + + connect( buttonClose, SIGNAL( clicked() ), this, SLOT( reject() ) ); + connect( buttonHelp, SIGNAL( clicked() ), this, SLOT( clickOnHelp() ) ); + + connect( myApp->selectionMgr(), SIGNAL( currentSelectionChanged() ), + this, SLOT( onViewSelectionChanged() ) ); + + connect( myApp->desktop(), SIGNAL( windowActivated( SUIT_ViewWindow* ) ), + this, SLOT( onWindowActivated( SUIT_ViewWindow* ) ) ); + + if ( myViewWindow ) + connect( myViewWindow->getViewManager(), SIGNAL( deleteView( SUIT_ViewWindow* ) ), + this, SLOT( onCloseView( SUIT_ViewWindow* ) ), Qt::UniqueConnection ); + + init(); +} + +RepairGUI_InspectObjectDlg::~RepairGUI_InspectObjectDlg() +{ + if ( myViewWindow ) + onEditMainShape(); + // restore initial parameters for viewer + getDisplayer()->UnsetColor(); + getDisplayer()->UnsetWidth(); + // no need to delete child widgets, Qt does it all for us +} + +//================================================================================= +// function : init() +// purpose : initialize dialog data +//================================================================================= +void RepairGUI_InspectObjectDlg::init() +{ + //get shape from selection + SALOME_ListIO selected; + myApp->selectionMgr()->selectedObjects(selected); + + if ( selected.Extent() != 1 ) + return; + + if ( !myViewWindow ) { + SUIT_ViewManager* occVm = myApp->getViewManager( OCCViewer_Viewer::Type(), true ); + myViewWindow = occVm->getActiveView(); + connect( occVm, SIGNAL( deleteView( SUIT_ViewWindow* ) ), + this, SLOT( onCloseView( SUIT_ViewWindow* ) ), Qt::UniqueConnection ); + } + + TopoDS_Shape aShape = GEOMBase::GetTopoFromSelection( selected ); + if ( aShape.IsNull() ) + return; + + Handle(SALOME_InteractiveObject) anIO = selected.First(); + GEOM::GEOM_Object_var anObject = GEOMBase::ConvertIOinGEOMObject( anIO ); + QString aName = anObject->GetName(); + CORBA::String_var anEntry = anObject->GetStudyEntry(); + + myEditMainShape->setText( aName ); + myEditMainShape->setEnabled( false ); + + // remember initial transparency value + SalomeApp_Study* aStudy = dynamic_cast( myApp->activeStudy() ); + QVariant v = aStudy->getObjectProperty( myViewWindow->getViewManager()->getGlobalId(), + QString( anEntry.in() ), + GEOM::propertyName( GEOM::Transparency ), myTransparency ); + if ( v.canConvert( QVariant::Double ) ) + myTransparency = v.toDouble(); + + TreeWidgetItem* anItem = new TreeWidgetItem( myTreeObjects, QStringList() << aName, aShape, anIO ); + if ( getDisplayer()->IsDisplayed( anEntry.in() ) ) + anItem->setVisible( true, myVisible ); + else + anItem->setVisible( false, myInvisible ); + + setMainObjectTransparency( 0.5 ); + + // add sub-objects in the tree + addSubObjects( anItem ); + + // check icon for tree header + checkVisibleIcon(); +} + +//================================================================================= +// function : checkVisibleIcon() +// purpose : set visible or invisible icon in the header of tree +//================================================================================= +void RepairGUI_InspectObjectDlg::checkVisibleIcon() +{ + bool isInvisible = false; + QTreeWidgetItemIterator it( myTreeObjects ); + while ( *it ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( !anItem->isVisible() ) + isInvisible = true; + ++it; + } + + if ( isInvisible ) { + myTreeObjects->headerItem()->setIcon( 1, myInvisible ); + myIsSelectAll = false; + } + else { + myTreeObjects->headerItem()->setIcon( 1, myVisible ); + myIsSelectAll = true; + } +} + +//================================================================================= +// function : addSubObjects() +// purpose : add sub-objects to parent object in the tree +//================================================================================= +void RepairGUI_InspectObjectDlg::addSubObjects( TreeWidgetItem* theParentItem ) +{ + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + TopoDS_Iterator it( theParentItem->getShape() ); + for ( ; it.More(); it.Next() ) { + TopoDS_Shape aSubShape = it.Value(); + int anIndex = GEOMBase::GetIndex( aSubShape, aMainItem->getShape() ); + QString anEntry = QString( "TEMP_" ) + aMainItem->getIO()->getEntry() + QString("_%1").arg( anIndex ); + TreeWidgetItem* anItem = new TreeWidgetItem( theParentItem, QStringList(), aSubShape, anEntry); + anItem->setVisible( false, myInvisible ); + addSubObjects( anItem ); + } +} + +//================================================================================= +// function : displayItem() +// purpose : display sub-object of inspected object according its tree item +//================================================================================= +void RepairGUI_InspectObjectDlg::displayItem( TreeWidgetItem* theItem ) +{ + GEOM_Displayer* aDisplayer = getDisplayer(); + if ( theItem == myTreeObjects->topLevelItem(0) ) { + aDisplayer->UnsetColor(); + aDisplayer->UnsetWidth(); + } + else if ( aDisplayer->GetColor() != Quantity_NOC_VIOLET && aDisplayer->GetWidth() != 2.0 ) { + aDisplayer->SetColor( Quantity_NOC_VIOLET ); + aDisplayer->SetWidth( 2.0 ); + } + + SALOME_Prs* aPrs = aDisplayer->buildSubshapePresentation( theItem->getShape(), theItem->getIO()->getEntry(), + GEOM_Displayer::GetActiveView() ); + if ( aPrs ) + displayPreview( aPrs, true, false ); +} + +//================================================================================= +// function : setItemDisplayStatus() +// purpose : set visible or invisible status for the same items in the tree +//================================================================================= +void RepairGUI_InspectObjectDlg::setItemDisplayStatus( TreeWidgetItem* theItem, bool theIsVisible ) +{ + QTreeWidgetItemIterator it( myTreeObjects ); + while (*it) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( anItem->getShape().IsSame( theItem->getShape() ) ) + anItem->setVisible( theIsVisible, theIsVisible ? myVisible : myInvisible ); + ++it; + } +} + +//================================================================================= +// function : setMainObjectTransparency() +// purpose : set transparency for the inspected object +//================================================================================= +void RepairGUI_InspectObjectDlg::setMainObjectTransparency( double theTransparency ) +{ + SUIT_ViewManager* aViewMan = myViewWindow->getViewManager(); + SALOME_View* aView = dynamic_cast( aViewMan->getViewModel() ); + SalomeApp_Study* aStudy = dynamic_cast( myApp->activeStudy() ); + + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + aStudy->setObjectProperty( myViewWindow->getViewManager()->getGlobalId(), + QString( aMainItem->getIO()->getEntry() ), + GEOM::propertyName( GEOM::Transparency ), theTransparency ); + + if ( aView->isVisible( aMainItem->getIO() ) ) + getDisplayer()->Redisplay( aMainItem->getIO(), true, aView ); +} + +//================================================================================= +// function : restoreParam() +// purpose : restore initial parameters of the dialog and the viewer +//================================================================================= +void RepairGUI_InspectObjectDlg::restoreParam() +{ + SUIT_ViewManager* aViewMan = myViewWindow->getViewManager(); + SALOME_View* aView = dynamic_cast( aViewMan->getViewModel() ); + GEOM_Displayer* aDisplayer = getDisplayer(); + // restore initial parameters for viewer + aDisplayer->UnsetColor(); + aDisplayer->UnsetWidth(); + + // restore transparency of main object + setMainObjectTransparency( myTransparency ); + + // erase sub-shapes + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + QTreeWidgetItemIterator it( myTreeObjects ); + while (*it) { + if ( *it != aMainItem ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + aDisplayer->Erase( anItem->getIO(), false, false, aView ); + anItem->setVisible( false, myInvisible ); + } + ++it; + } +} + +//================================================================================= +// function : onEditMainShape() +// purpose : called when selection button was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::onEditMainShape() +{ + if ( myEditMainShape->text().isEmpty() || !myViewWindow ) + return; + + restoreParam(); + + // restore initial parameters for dialog box + myEditMainShape->setEnabled( true ); + myEditMainShape->setText(""); + myEditMainShape->setFocus(); + myTreeObjects->clear(); +} + +//================================================================================= +// function : onItemClicked() +// purpose : called when tree item was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::onItemClicked( QTreeWidgetItem* theItem, int theColumn ) +{ + if ( theColumn!= 1 || !( theItem->flags() & Qt::ItemIsSelectable ) || !myViewWindow ) + return; + + GEOM_Displayer* aDisplayer = getDisplayer(); + + TreeWidgetItem* anItem = dynamic_cast( theItem ); + + if ( anItem->isVisible() ) { + aDisplayer->Erase( anItem->getIO(), false, true ); + setItemDisplayStatus( anItem, false ); + } + else { + displayItem( anItem ); + setItemDisplayStatus( anItem, true ); + } + aDisplayer->UpdateViewer(); + checkVisibleIcon(); +} + +//================================================================================= +// function : onItemChanged() +// purpose : called when tree item was changed +//================================================================================= +void RepairGUI_InspectObjectDlg::onItemChanged( QTreeWidgetItem* theItem, int theColumn ) +{ + if ( theColumn!= 0 || !( theItem->flags() & Qt::ItemIsEditable ) ) + return; + + // rename the same items in the tree + QTreeWidgetItemIterator it( myTreeObjects ); + while ( *it ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( anItem->getShape().IsSame( dynamic_cast( theItem )->getShape() ) ) + anItem->setText( 0, theItem->text(0) ); + ++it; + } +} + +//================================================================================= +// function : onItemExpanded() +// purpose : called when tree item was expanded +//================================================================================= +void RepairGUI_InspectObjectDlg::onItemExpanded( QTreeWidgetItem* theItem ) +{ + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + GEOM::GEOM_Object_var aMainObject = GEOMBase::ConvertIOinGEOMObject( aMainItem->getIO() ); + + for ( int i = 0; i < theItem->childCount(); i++ ) { + TreeWidgetItem* aSubItem = dynamic_cast( theItem->child(i) ); + int anIndex = GEOMBase::GetIndex( aSubItem->getShape(), aMainItem->getShape() ); + if ( aSubItem->text(0).isEmpty() ) { + char* aName = aMainObject->GetSubShapeName( anIndex ); + if ( !QString( aName ).isEmpty() ) + aSubItem->setText( 0, QString( aName ) ); + else + aSubItem->setText( 0, QString("%1_%2").arg( GEOMBase::TypeName( aSubItem->getShape().ShapeType(), true ) ).arg( anIndex ) ); + } + } +} + +//================================================================================= +// function : onItemSelectionChanged() +// purpose : called when tree item was selected +//================================================================================= +void RepairGUI_InspectObjectDlg::onItemSelectionChanged() +{ + if ( !myViewWindow ) + return; + + QList listItem = myTreeObjects->selectedItems(); + SALOME_ListIO aSelected; + for ( int i = 0; i < listItem.size(); i++ ) { + TreeWidgetItem* anItem = dynamic_cast( listItem.at(i) ); + aSelected.Append( anItem->getIO() ); + } + myApp->selectionMgr()->setSelectedObjects( aSelected ); +} + +//================================================================================= +// function : onHeaderClicked() +// purpose : called when header item of tree was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::onHeaderClicked( int theColumn ) +{ + if ( theColumn != 1 || !myViewWindow ) + return; + + GEOM_Displayer* aDisplayer = getDisplayer(); + + if ( myIsSelectAll ) { + myIsSelectAll = false; + myTreeObjects->headerItem()->setIcon( 1, myInvisible ); + SALOME_ListIO aListOfIO; + QTreeWidgetItemIterator it( myTreeObjects ); + while ( *it ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( ( anItem->flags() & Qt::ItemIsSelectable ) && anItem->isVisible() ) { + aListOfIO.Append( anItem->getIO() ); + anItem->setVisible( false, myInvisible ); + } + ++it; + } + aDisplayer->Erase( aListOfIO ); + } + else { + myIsSelectAll = true; + myTreeObjects->headerItem()->setIcon( 1, myVisible ); + QTreeWidgetItemIterator it( myTreeObjects ); + while ( *it ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( ( anItem->flags() & Qt::ItemIsSelectable ) && !anItem->isVisible() ) { + displayItem( anItem ); + anItem->setVisible( true, myVisible ); + } + ++it; + } + } + + aDisplayer->UpdateViewer(); +} + +//================================================================================= +// function : onViewSelectionChanged() +// purpose : called when selection of object browser was changed +//================================================================================= +void RepairGUI_InspectObjectDlg::onViewSelectionChanged() +{ + if ( myEditMainShape->isEnabled() ) + init(); +} + +//================================================================================= +// function : onWindowActivated() +// purpose : called when other window was activated +//================================================================================= +void RepairGUI_InspectObjectDlg::onWindowActivated( SUIT_ViewWindow* theViewWindow ) +{ + if ( myViewWindow ) + restoreParam(); + + connect( theViewWindow->getViewManager(), SIGNAL( deleteView( SUIT_ViewWindow* ) ), + this, SLOT( onCloseView( SUIT_ViewWindow* ) ), Qt::UniqueConnection ); + + if ( theViewWindow->getViewManager()->getType() != OCCViewer_Viewer::Type() && + theViewWindow->getViewManager()->getType() != SVTK_Viewer::Type() ) { + myViewWindow = 0; + return; + } + myViewWindow = theViewWindow; + + if ( myTreeObjects->topLevelItemCount() > 0 ) { + setMainObjectTransparency( 0.5 ); + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + if ( getDisplayer()->IsDisplayed( aMainItem->getIO()->getEntry() ) ) + aMainItem->setVisible( true, myVisible ); + else + aMainItem->setVisible( false, myInvisible ); + } + checkVisibleIcon(); +} + +//================================================================================= +// function : onCloseView() +// purpose : called when last view was closed +//================================================================================= +void RepairGUI_InspectObjectDlg::onCloseView( SUIT_ViewWindow* ) +{ + if ( myApp->desktop()->windows().size() == 0 ) { + restoreParam(); + myViewWindow = 0; + } +} + +//================================================================================= +// function : clickOnShow() +// purpose : called when "Show selected" button was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::clickOnShow() +{ + if ( !myViewWindow ) + return; + + QList listItem = myTreeObjects->selectedItems(); + for ( int i = 0; i < listItem.size(); i++ ) { + TreeWidgetItem* anItem = dynamic_cast( listItem.at(i) ); + if ( !anItem->isVisible() ) { + displayItem( anItem ); + setItemDisplayStatus( anItem, true ); + } + } + getDisplayer()->UpdateViewer(); + checkVisibleIcon(); +} + +//================================================================================= +// function : clickOnShowOnly() +// purpose : called when "Show only selected" button was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::clickOnShowOnly() +{ + if ( !myViewWindow ) + return; + + SALOME_ListIO aListOfIO; + QTreeWidgetItemIterator it( myTreeObjects ); + while ( *it ) { + TreeWidgetItem* anItem = dynamic_cast(*it); + if ( ( anItem->flags() & Qt::ItemIsSelectable ) && anItem->isVisible() ) { + aListOfIO.Append( anItem->getIO() ); + anItem->setVisible( false, myInvisible ); + } + ++it; + } + getDisplayer()->Erase( aListOfIO ); + + clickOnShow(); +} + +//================================================================================= +// function : clickOnHide() +// purpose : called when "Hide selected" button was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::clickOnHide() +{ + if ( !myViewWindow ) + return; + + QList listItem = myTreeObjects->selectedItems(); + for ( int i = 0; i < listItem.size(); i++ ) { + TreeWidgetItem* anItem = dynamic_cast( listItem.at(i) ); + if ( anItem->isVisible() ) { + getDisplayer()->Erase( anItem->getIO(), false, false ); + setItemDisplayStatus( anItem, false ); + } + } + getDisplayer()->UpdateViewer(); + checkVisibleIcon(); +} + +//================================================================================= +// function : clickOnPublish() +// purpose : called when "Publish selected" button was clicked +//================================================================================= +void RepairGUI_InspectObjectDlg::clickOnPublish() +{ + _PTR(Study) studyDS = dynamic_cast( myApp->activeStudy() )->studyDS(); + + // find main object + TreeWidgetItem* aMainItem = dynamic_cast( myTreeObjects->topLevelItem(0) ); + GEOM::GEOM_Object_var aMainObject = GEOMBase::ConvertIOinGEOMObject( aMainItem->getIO() ); + + // find unique indices of selected objects + QList selectedItems = myTreeObjects->selectedItems(); + QMap< int, QString > anIndices; + GEOM::ListOfLong_var anArray = new GEOM::ListOfLong; + anArray->length( selectedItems.size() ); + int j = 0; + for ( int i = 0; i < selectedItems.size(); i++ ) { + TreeWidgetItem* anItem = dynamic_cast( selectedItems.at(i) ); + int anIndex = GEOMBase::GetIndex( anItem->getShape(), aMainItem->getShape() ); + if ( anIndices.find( anIndex ) == anIndices.end() && + anItem != aMainItem ) { + anIndices[ anIndex ] = anItem->text(0); + anArray[j++] = anIndex; + } + } + anArray->length(j); + + // get selected sub-shapes + GEOM::GEOM_IShapesOperations_var anOper = getGeomEngine()->GetIShapesOperations( getStudyId() ); + GEOM::ListOfGO_var aList = anOper->MakeSubShapes( aMainObject, anArray ); + + // publish sub-shapes + for ( int i = 0; i < aList->length(); i++ ) + GeometryGUI::GetGeomGen()->AddInStudy( GeometryGUI::ClientStudyToStudy( studyDS ), aList[i], + anIndices.values().at(i).toStdString().c_str(), aMainObject ); + + updateObjBrowser(); +} + +//================================================================================= +// function : clickOnHelp() +// purpose : called when Help button was clicked to open a help page +//================================================================================= +void RepairGUI_InspectObjectDlg::clickOnHelp() +{ + myApp->onHelpContextModule( "GEOM", "inspect_object_operation_page.html" ); +} diff --git a/src/RepairGUI/RepairGUI_InspectObjectDlg.h b/src/RepairGUI/RepairGUI_InspectObjectDlg.h new file mode 100644 index 000000000..ecb9ab6f2 --- /dev/null +++ b/src/RepairGUI/RepairGUI_InspectObjectDlg.h @@ -0,0 +1,88 @@ +// Copyright (C) 2014 CEA/DEN, EDF R&D, OPEN CASCADE +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// 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 +// + +#ifndef RepairGUI_InspectObjectDlg_H +#define RepairGUI_InspectObjectDlg_H + +// GEOM includes +#include + +// Qt includes +#include +#include +#include +#include +#include + +class RepairGUI_InspectObjectDlg : public QDialog, public GEOMBase_Helper +{ + Q_OBJECT + + class TreeWidgetItem; + class Delegate; + +public: + RepairGUI_InspectObjectDlg( SUIT_Desktop* ); + ~RepairGUI_InspectObjectDlg(); + +private slots: + void onEditMainShape(); + + void onItemClicked( QTreeWidgetItem*, int ); + void onItemChanged( QTreeWidgetItem*, int ); + void onItemSelectionChanged(); + void onItemExpanded( QTreeWidgetItem* ); + void onHeaderClicked( int ); + void onItemDoubleClicked( QTreeWidgetItem*, int ); + + void onViewSelectionChanged(); + + void onWindowActivated( SUIT_ViewWindow* ); + void onCloseView( SUIT_ViewWindow* ); + + void clickOnShow(); + void clickOnShowOnly(); + void clickOnHide(); + void clickOnPublish(); + void clickOnHelp(); + +private: + void init(); + void checkVisibleIcon(); + void addSubObjects( TreeWidgetItem* ); + void displayItem( TreeWidgetItem* ); + void setItemDisplayStatus( TreeWidgetItem* theItem, bool theIsVisible ); + void setMainObjectTransparency( double ); + void restoreParam(); + + SalomeApp_Application* myApp; + QPointer myViewWindow; + + QIcon myVisible; + QIcon myInvisible; + + QTreeWidget* myTreeObjects; + QLineEdit* myEditMainShape; + + bool myIsSelectAll; + double myTransparency; + +}; + +#endif -- 2.39.2