1 #include "DocumentTut.h"
5 #include <QApplication>
7 #include <TopoDS_Shape.hxx>
8 #include <AIS_Shape.hxx>
11 MakeBottle(const Standard_Real myWidth , const Standard_Real myHeight , const Standard_Real myThickness);
13 DocumentTut::DocumentTut( const int theIndex, ApplicationCommonWindow* app )
14 : DocumentCommon( theIndex, app )
18 DocumentTut::~DocumentTut()
22 void DocumentTut::onMakeBottle()
24 QApplication::setOverrideCursor( Qt::WaitCursor );
25 TopoDS_Shape aBottle=MakeBottle(50,70,30);
26 Handle(AIS_Shape) AISBottle=new AIS_Shape(aBottle);
27 getContext()->SetMaterial(AISBottle,Graphic3d_NOM_GOLD);
28 getContext()->SetDisplayMode(AISBottle,1,Standard_False);
29 getContext()->Display(AISBottle, Standard_False);
30 getContext()->SetCurrentObject(AISBottle,Standard_False);
31 emit selectionChanged();
33 QApplication::restoreOverrideCursor();