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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
|
-- File : Prs2d_RadiusIndep.cdl
-- Created : October 2000
-- Author : Tanya COOL
---Copyright: Matra Datavision 2000
class RadiusIndep from Prs2d inherits Line from Graphic2d
---Purpose: Constructs the primitive Radius
uses
Drawer from Graphic2d,
GraphicObject from Graphic2d,
Pnt2d from gp,
ExtendedString from TCollection,
TypeOfRadius from Prs2d,
Arrow from Prs2d,
Array1OfShortReal from TShort,
FStream from Aspect
raises
ConstructionError from Standard
is
Create( aGO : GraphicObject from Graphic2d;
anAttachPnt : Pnt2d from gp;
aCenter : Pnt2d from gp;
aRad : Real from Standard;
aText : ExtendedString from TCollection;
aLength : Real from Standard = 10.0;
aTypeRad : TypeOfRadius from Prs2d = Prs2d_TOR_STANDARD;
aTxtScale : Real from Standard = 1.0)
returns mutable RadiusIndep from Prs2d;
---Purpose: Creates the radius of the circle <aCenter, aRad> passing through
-- the point <anAttachPnt1> on the circle
----------------------------------------------------
-- Category: Draw and Pick
----------------------------------------------------
Draw( me : mutable; aDrawer: Drawer from Graphic2d )
is static protected;
---Level: Internal
---Purpose: Draws the angle <me>.
DrawElement( me : mutable; aDrawer: Drawer from Graphic2d;
anIndex: Integer from Standard)
is redefined protected;
---Level: Internal
---Purpose: Draws element <anIndex> of the radius <me>.
DrawVertex( me : mutable; aDrawer: Drawer from Graphic2d;
anIndex: Integer from Standard)
is redefined protected;
---Level: Internal
---Purpose: Draws vertex <anIndex> of the radius <me>.
Pick( me : mutable; X, Y: ShortReal from Standard;
aPrecision: ShortReal from Standard;
aDrawer: Drawer from Graphic2d)
returns Boolean from Standard
is static protected;
---Level: Internal
---Purpose: Returns Standard_True if the radius <me> is picked,
-- Standard_False if not.
--------------------------------------
-- Category: Inquire methods
--------------------------------------
Values( me;
anAttPnt, aCenter: out Pnt2d from gp;
aRad : out Real from Standard;
aText : out ExtendedString from TCollection;
aLength : out Real from Standard;
aTypeRad : out TypeOfRadius from Prs2d;
aTxtScale : out Real from Standard );
---Level: Internal
---Purpose: allows to get the properties of the radius
--------------------------------------------
-- Category: Modification of the properties
--------------------------------------------
SetText( me: mutable; aTxt: ExtendedString from TCollection );
---Level: Public
---Purpose: Defines the text
SetTextScale( me: mutable; aTxtScale: Real from Standard );
---Level: Public
---Purpose: Defines the scale factor of text
SetTextFont( me: mutable; aTF: Integer from Standard );
---Level: Public
---Purpose: Sets the index of the font of this text to this dimension
SetFontOfSymb( me: mutable; aFS: Integer from Standard );
---Level: Public
---Purpose: Sets the index of the font of the symbol to this dimension
DrawSymbol( me: mutable; isDraw: Boolean from Standard );
---Level: Public
---Purpose: Sets the flag for drawing additional symbol
SetSymbolCode( me: mutable; aCode: Integer from Standard );
---Level: Public
---Purpose: Sets the ASCII code of the symbol
TextFont( me ) returns Integer from Standard;
---Level: Public
---Purpose: Returns the index of the font of this text of this dimension
FontOfSymb( me ) returns Integer from Standard;
---Level: Public
---Purpose: Returns the index of the font of the symbol of this dimension
IsDrawSymbol( me ) returns Boolean from Standard;
---Level: Public
---Purpose: Return true if symbol is drawn, false - in otherwise
SymbolCode( me ) returns Integer from Standard;
---Level: Public
---Purpose: Return ASCII code of the symbol
Save( me; aFStream: in out FStream from Aspect ) is virtual;
fields
myX1 : ShortReal from Standard;
myY1 : ShortReal from Standard;
myX2 : ShortReal from Standard;
myY2 : ShortReal from Standard;
myTextScale : ShortReal from Standard;
myText : ExtendedString from TCollection;
myTextX : ShortReal from Standard;
myTextY : ShortReal from Standard;
myTextAng : ShortReal from Standard;
myInside : Boolean from Standard;
myXVert : Array1OfShortReal from TShort;
myYVert : Array1OfShortReal from TShort;
myIsSymbol : Boolean from Standard;
mySymbCode : Integer from Standard;
myTextFont : Integer from Standard;
mySymbFont : Integer from Standard;
myAttPnt : Pnt2d from gp;
myCenter : Pnt2d from gp;
myRadius : Real from Standard;
myLength : Real from Standard;
myRadType : TypeOfRadius from Prs2d;
end RadiusIndep from Prs2d;
|