1 // Created on: 1994-11-17
2 // Created by: Jean Yves LEBEY
3 // Copyright (c) 1994-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
18 #include <Draw_Color.hxx>
19 #include <Draw_Display.hxx>
20 #include <Draw_Text3D.hxx>
22 #include <Standard_Type.hxx>
23 #include <TestTopOpeDraw_DrawableP3D.hxx>
25 IMPLEMENT_STANDARD_RTTIEXT(TestTopOpeDraw_DrawableP3D,Draw_Marker3D)
27 //=======================================================================
28 //function : TestTopOpeDraw_DrawableP3D
30 //=======================================================================
31 TestTopOpeDraw_DrawableP3D::TestTopOpeDraw_DrawableP3D
33 const Draw_Color& PColor,
34 const Standard_Real MoveX,
35 const Standard_Real MoveY) :
36 Draw_Marker3D(P,Draw_Square,PColor,2), // Size
43 myText3D = new Draw_Text3D(myPnt,myText,myTextColor, myMoveX, myMoveY);
46 //=======================================================================
47 //function : TestTopOpeDraw_DrawableP3D
49 //=======================================================================
51 TestTopOpeDraw_DrawableP3D::TestTopOpeDraw_DrawableP3D
52 (const gp_Pnt& P, const Draw_Color& PColor,
53 const Standard_CString Text, const Draw_Color& TextColor,
54 const Standard_Real MoveX,
55 const Standard_Real MoveY) :
56 Draw_Marker3D(P,Draw_Square,PColor,2), // Size
59 myTextColor(TextColor),
63 myText3D = new Draw_Text3D(myPnt,myText,myTextColor, myMoveX, myMoveY);
66 //=======================================================================
67 //function : TestTopOpeDraw_DrawableP3D
69 //=======================================================================
71 TestTopOpeDraw_DrawableP3D::TestTopOpeDraw_DrawableP3D
72 (const gp_Pnt& P, const Draw_MarkerShape T, const Draw_Color& PColor,
73 const Standard_CString Text, const Draw_Color& TextColor,
74 const Standard_Integer Size,
75 const Standard_Real MoveX,
76 const Standard_Real MoveY) :
77 Draw_Marker3D(P,T,PColor,Size),
80 myTextColor(TextColor),
84 myText3D = new Draw_Text3D(myPnt,myText,myTextColor, myMoveX, myMoveY);
87 //=======================================================================
88 //function : TestTopOpeDraw_DrawableP3D
90 //=======================================================================
92 TestTopOpeDraw_DrawableP3D::TestTopOpeDraw_DrawableP3D
93 (const gp_Pnt& P, const Draw_MarkerShape T,
94 const Draw_Color& PColor, const Standard_CString Text,
95 const Draw_Color& TextColor, const Standard_Real Tol,
96 const Standard_Real MoveX, const Standard_Real MoveY) :
97 Draw_Marker3D(P, T, PColor, Tol),
100 myTextColor(TextColor),
104 myText3D = new Draw_Text3D(myPnt,myText,myTextColor, myMoveX, myMoveY);
107 //=======================================================================
108 //function : ChangePnt
110 //=======================================================================
112 void TestTopOpeDraw_DrawableP3D::ChangePnt(const gp_Pnt& P)
115 myText3D = new Draw_Text3D(myPnt, myText, myTextColor, myMoveX, myMoveY);
120 //=======================================================================
123 //=======================================================================
125 void TestTopOpeDraw_DrawableP3D::DrawOn(Draw_Display& dis) const
127 Draw_Marker3D::DrawOn(dis);
128 myText3D->DrawOn(dis);