20 #ifndef PartSet_OperationPrs_H
21 #define PartSet_OperationPrs_H
25 #include <ModelAPI_Object.h>
26 #include <ModelAPI_Feature.h>
27 #include <ModelAPI_Result.h>
28 #include <ModelAPI_Attribute.h>
30 #include <ModuleBase_IWorkshop.h>
32 #include <GeomAPI_Shape.h>
34 #include <ViewerData_AISShape.hxx>
35 #include <Standard_DefineHandle.hxx>
37 #include <Quantity_Color.hxx>
38 #include <NCollection_List.hxx>
39 #include <NCollection_DataMap.hxx>
40 #include <TopoDS_Shape.hxx>
41 #include <AIS_InteractiveObject.hxx>
51 class SelectMgr_Selection;
81 Standard_EXPORT
virtual void Compute(
82 const Handle(PrsMgr_PresentationManager3d)& thePresentationManager,
83 const Handle(Prs3d_Presentation)& thePresentation,
const Standard_Integer theMode = 0);
86 Standard_EXPORT
virtual void ComputeSelection(
const Handle(SelectMgr_Selection)& aSelection,
87 const Standard_Integer aMode) ;
101 static void getFeatureShapes(
const FeaturePtr& theFeature,
103 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes);
111 static void getResultShapes(
const FeaturePtr& theFeature,
113 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes,
114 const bool theListShouldBeCleared =
true);
121 static void getPresentationShapes(
const FeaturePtr& theFeature,
123 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes,
124 const bool theListShouldBeCleared =
true);
132 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes);
137 static bool isSelectionAttribute(
const AttributePtr& theAttribute);
145 static void addValue(
const ObjectPtr& theObject,
const GeomShapePtr& theShape,
147 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes);
156 const ObjectPtr& theObject,
157 GeomShapePtr theGeomShape,
158 QMap<ObjectPtr, QList<GeomShapePtr> >& theObjectShapes);
163 static void fillShapeList(
const QMap<ObjectPtr, QList<GeomShapePtr> >& theFeatureShapes,
172 Quantity_Color myShapeColor;
Class which provides access to Workshop object services.
Definition: ModuleBase_IWorkshop.h:48
This is the module custom presentation, which manage an AIS presentation, that can be filled by a fea...
Definition: PartSet_CustomPrs.h:46
A redefinition of standard AIS Interactive Object in order to provide colored presentation of a list ...
Definition: PartSet_OperationPrs.h:62
PartSet_OperationPrs(ModuleBase_IWorkshop *theWorkshop)
Constructor.
Definition: PartSet_OperationPrs.cpp:75
void useAISWidth()
Switch on using of the AIS presentation with of the shape object increased on the delta.
Definition: PartSet_OperationPrs.cpp:108
virtual DEFINE_STANDARD_RTTIEXT(PartSet_OperationPrs, ViewerData_AISShape) protected void ComputeSelection(const Handle &&aSelection, const Standard_Integer aMode)
Redefinition of virtual function.
Definition: PartSet_OperationPrs.cpp:172
void setShapeColor(const Quantity_Color &theColor)
Sets the colors for the presentation compute.
Definition: PartSet_OperationPrs.cpp:103
bool hasShapes()
Returns true if the feature contains shapes or results.
Definition: PartSet_OperationPrs.cpp:98
NCollection_DataMap< TopoDS_Shape, Handle > & shapesMap()
list of visualized shapes
Definition: PartSet_OperationPrs.cpp:178
Displayer.
Definition: XGUI_Displayer.h:172