1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
|
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to
// this header file considered to be the "object code" form of the original source.
#ifndef _Prs2d_AspectText_HeaderFile
#define _Prs2d_AspectText_HeaderFile
#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Standard_DefineHandle_HeaderFile
#include <Standard_DefineHandle.hxx>
#endif
#ifndef _Handle_Prs2d_AspectText_HeaderFile
#include <Handle_Prs2d_AspectText.hxx>
#endif
#ifndef _Quantity_Color_HeaderFile
#include <Quantity_Color.hxx>
#endif
#ifndef _Aspect_FontStyle_HeaderFile
#include <Aspect_FontStyle.hxx>
#endif
#ifndef _Quantity_PlaneAngle_HeaderFile
#include <Quantity_PlaneAngle.hxx>
#endif
#ifndef _Aspect_TypeOfText_HeaderFile
#include <Aspect_TypeOfText.hxx>
#endif
#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _Prs2d_AspectRoot_HeaderFile
#include <Prs2d_AspectRoot.hxx>
#endif
#ifndef _Quantity_NameOfColor_HeaderFile
#include <Quantity_NameOfColor.hxx>
#endif
#ifndef _Standard_CString_HeaderFile
#include <Standard_CString.hxx>
#endif
#ifndef _Quantity_Length_HeaderFile
#include <Quantity_Length.hxx>
#endif
#ifndef _Aspect_TypeOfFont_HeaderFile
#include <Aspect_TypeOfFont.hxx>
#endif
class Quantity_Color;
class Aspect_FontStyle;
//! defines the attributes when drawing a text presentation <br>
class Prs2d_AspectText : public Prs2d_AspectRoot {
public:
//! constructor using basic aspect types. <br>
Standard_EXPORT Prs2d_AspectText(const Quantity_NameOfColor aColor = Quantity_NOC_YELLOW,const Standard_CString aFont = "TABTXT03",const Quantity_Length anHeight = 3.0,const Aspect_TypeOfText aType = Aspect_TOT_SOLID,const Standard_Boolean isUnderlined = Standard_False);
//! constructor using advanced aspect types. <br>
Standard_EXPORT Prs2d_AspectText(const Quantity_Color& aColor,const Aspect_FontStyle& aFont,const Aspect_TypeOfText aType = Aspect_TOT_SOLID,const Standard_Boolean isUnderlined = Standard_False);
//! Change the color aspect with a predefined color. <br>
Standard_EXPORT void SetColor(const Quantity_NameOfColor aColor) ;
//! Change the color aspect. <br>
Standard_EXPORT void SetColor(const Quantity_Color& aColor) ;
//! Change the font style aspect <br>
Standard_EXPORT void SetFont(const Aspect_FontStyle& aFont) ;
//! Change the font style aspect with a new font type but <br>
//! preserve all other parameters. <br>
Standard_EXPORT void SetFont(const Aspect_TypeOfFont aFont) ;
//! Change the font style aspect with a new font slant <br>
//! added to the font original slant but preserve all other parameters. <br>
Standard_EXPORT void SetRelativeSlant(const Quantity_PlaneAngle aSlant) ;
//! Change the font style aspect with a new font height <br>
//! and CapsHeight indicator but preserve all other parameters. <br>
Standard_EXPORT void SetHeight(const Quantity_Length anHeight,const Standard_Boolean isCapsHeight) ;
//! Change the char type aspect of bolded fonts. <br>
Standard_EXPORT void SetType(const Aspect_TypeOfText aType) ;
//! Enable / Disable the underlined char aspect. <br>
Standard_EXPORT void SetUnderlined(const Standard_Boolean anIsUnderline) ;
//! Returns the current parameters of this text aspect. <br>
Standard_EXPORT void Values(Quantity_Color& aColor,Aspect_FontStyle& aFont,Quantity_PlaneAngle& aSlant,Aspect_TypeOfText& aType,Standard_Boolean& isUnderlined) const;
//! Returns the current font index according to the font style aspect <br>
Standard_EXPORT Standard_Integer FontIndex() const;
//! Returns the current color index according to the color aspect <br>
Standard_EXPORT Standard_Integer ColorIndex() const;
//! Sets the current color index according to the color aspect <br>
Standard_EXPORT void SetFontIndex(const Standard_Integer anInd) ;
//! Sets the current color index according to the color aspect <br>
Standard_EXPORT void SetColorIndex(const Standard_Integer anInd) ;
DEFINE_STANDARD_RTTI(Prs2d_AspectText)
protected:
private:
Quantity_Color myColor;
Aspect_FontStyle myFont;
Quantity_PlaneAngle myRelativeSlant;
Aspect_TypeOfText myType;
Standard_Boolean myIsUnderlined;
Standard_Integer myFontIndex;
Standard_Integer myColorIndex;
};
// other Inline functions and methods (like "C++: function call" methods)
#endif
|