b311480e |
1 | -- Created on: 1993-06-11 |
2 | -- Created by: Jean-Louis FRENKEL |
3 | -- Copyright (c) 1993-1999 Matra Datavision |
4 | -- Copyright (c) 1999-2012 OPEN CASCADE SAS |
5 | -- |
6 | -- The content of this file is subject to the Open CASCADE Technology Public |
7 | -- License Version 6.5 (the "License"). You may not use the content of this file |
8 | -- except in compliance with the License. Please obtain a copy of the License |
9 | -- at http://www.opencascade.org and read it completely before using this file. |
10 | -- |
11 | -- The Initial Developer of the Original Code is Open CASCADE S.A.S., having its |
12 | -- main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France. |
13 | -- |
14 | -- The Original Code and all software distributed under the License is |
15 | -- distributed on an "AS IS" basis, without warranty of any kind, and the |
16 | -- Initial Developer hereby disclaims all such warranties, including without |
17 | -- limitation, any warranties of merchantability, fitness for a particular |
18 | -- purpose or non-infringement. Please see the License for the specific terms |
19 | -- and conditions governing the rights and limitations under the License. |
20 | |
7fd59977 |
21 | -- Modified GG : GER61351 01/02/00 Add SetColor() & Aspect() methods |
7fd59977 |
22 | |
23 | |
a6eb515f |
24 | class ArrowAspect from Prs3d inherits BasicAspect from Prs3d |
7fd59977 |
25 | ---Purpose: A framework for displaying arrows in representations |
26 | -- of dimensions and relations. |
27 | uses |
28 | Length from Quantity, |
29 | PlaneAngle from Quantity, |
30 | NameOfColor from Quantity, |
31 | Color from Quantity, |
32 | AspectLine3d from Graphic3d |
33 | |
34 | raises |
35 | InvalidAngle from Prs3d |
36 | |
37 | is |
38 | Create returns mutable ArrowAspect from Prs3d; |
39 | ---Purpose: Constructs an empty framework for displaying arrows |
40 | -- in representations of lengths. The lengths displayed |
41 | -- are either on their own or in chamfers, fillets, |
42 | -- diameters and radii. |
43 | Create (anAngle: PlaneAngle from Quantity; aLength: Length from Quantity) |
44 | returns mutable ArrowAspect from Prs3d; |
45 | --- Purpose: Constructs a framework to display an arrow with a |
46 | -- shaft of the length aLength and having a head with |
47 | -- sides at the angle anAngle from each other. |
48 | |
49 | SetAngle(me: mutable; anAngle: PlaneAngle from Quantity) |
50 | ---Purpose: defines the angle of the arrows. |
51 | raises InvalidAngle from Prs3d |
52 | is static; |
53 | |
54 | Angle(me) returns PlaneAngle from Quantity |
55 | ---Purpose: returns the current value of the angle used when drawing an arrow. |
56 | is static; |
57 | |
58 | SetLength(me: mutable; aLength: Length from Quantity) |
59 | ---Purpose: defines the length of the arrows. |
60 | is static; |
61 | |
62 | Length(me) returns Length from Quantity |
63 | ---Purpose: returns the current value of the length used when drawing an arrow. |
64 | is static; |
65 | |
66 | SetColor(me: mutable; aColor: Color from Quantity); |
67 | |
68 | SetColor(me: mutable; aColor: NameOfColor from Quantity); |
69 | |
70 | Aspect(me) returns AspectLine3d from Graphic3d; |
71 | |
7fd59977 |
72 | fields |
73 | myArrowAspect: AspectLine3d from Graphic3d; |
74 | myAngle: PlaneAngle from Quantity; |
75 | myLength: Length from Quantity; |
76 | |
77 | end ArrowAspect from Prs3d; |