1 #include "XGUI_Displayer.h"
2 #include "XGUI_Tools.h"
3 #include "XGUI_Viewer.h"
5 #include <ModelAPI_Document.h>
7 #include <AIS_InteractiveContext.hxx>
8 #include <AIS_Shape.hxx>
13 XGUI_Displayer::XGUI_Displayer(XGUI_Viewer* theViewer)
21 XGUI_Displayer::~XGUI_Displayer()
27 * \param theFeature a feature instance
29 void XGUI_Displayer::Display(boost::shared_ptr<ModelAPI_Feature> theFeature)
34 * Display the feature and a shape. This shape would be associated to the given feature
35 * \param theFeature a feature instance
36 * \param theFeature a shape
38 void XGUI_Displayer::Display(boost::shared_ptr<ModelAPI_Feature> theFeature,
39 const TopoDS_Shape& theShape)
41 Handle(AIS_InteractiveContext) aContext = myViewer->AISContext();
43 Handle(AIS_Shape) anAIS = new AIS_Shape(theShape);
44 aContext->Display(anAIS, Standard_False);
46 aContext->UpdateCurrentViewer();