973c2be1 |
1 | // Copyright (c) 1999-2014 OPEN CASCADE SAS |
b311480e |
2 | // |
973c2be1 |
3 | // This file is part of Open CASCADE Technology software library. |
b311480e |
4 | // |
d5f74e42 |
5 | // This library is free software; you can redistribute it and/or modify it under |
6 | // the terms of the GNU Lesser General Public License version 2.1 as published |
973c2be1 |
7 | // by the Free Software Foundation, with special exception defined in the file |
8 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
9 | // distribution for complete text of the license and disclaimer of any warranty. |
b311480e |
10 | // |
973c2be1 |
11 | // Alternatively, this file may be used under the terms of Open CASCADE |
12 | // commercial license or contractual agreement. |
b311480e |
13 | |
7fd59977 |
14 | |
42cf5bc1 |
15 | #include <Standard_Type.hxx> |
16 | #include <StepGeom_Axis2Placement.hxx> |
17 | #include <StepVisual_FontSelect.hxx> |
18 | #include <StepVisual_TextLiteral.hxx> |
19 | #include <TCollection_HAsciiString.hxx> |
7fd59977 |
20 | |
21 | StepVisual_TextLiteral::StepVisual_TextLiteral () {} |
22 | |
23 | void StepVisual_TextLiteral::Init( |
24 | const Handle(TCollection_HAsciiString)& aName) |
25 | { |
26 | |
27 | StepRepr_RepresentationItem::Init(aName); |
28 | } |
29 | |
30 | void StepVisual_TextLiteral::Init( |
31 | const Handle(TCollection_HAsciiString)& aName, |
32 | const Handle(TCollection_HAsciiString)& aLiteral, |
33 | const StepGeom_Axis2Placement& aPlacement, |
34 | const Handle(TCollection_HAsciiString)& aAlignment, |
35 | const StepVisual_TextPath aPath, |
36 | const StepVisual_FontSelect& aFont) |
37 | { |
38 | // --- classe own fields --- |
39 | literal = aLiteral; |
40 | placement = aPlacement; |
41 | alignment = aAlignment; |
42 | path = aPath; |
43 | font = aFont; |
44 | // --- classe inherited fields --- |
45 | StepRepr_RepresentationItem::Init(aName); |
46 | } |
47 | |
48 | |
49 | void StepVisual_TextLiteral::SetLiteral(const Handle(TCollection_HAsciiString)& aLiteral) |
50 | { |
51 | literal = aLiteral; |
52 | } |
53 | |
54 | Handle(TCollection_HAsciiString) StepVisual_TextLiteral::Literal() const |
55 | { |
56 | return literal; |
57 | } |
58 | |
59 | void StepVisual_TextLiteral::SetPlacement(const StepGeom_Axis2Placement& aPlacement) |
60 | { |
61 | placement = aPlacement; |
62 | } |
63 | |
64 | StepGeom_Axis2Placement StepVisual_TextLiteral::Placement() const |
65 | { |
66 | return placement; |
67 | } |
68 | |
69 | void StepVisual_TextLiteral::SetAlignment(const Handle(TCollection_HAsciiString)& aAlignment) |
70 | { |
71 | alignment = aAlignment; |
72 | } |
73 | |
74 | Handle(TCollection_HAsciiString) StepVisual_TextLiteral::Alignment() const |
75 | { |
76 | return alignment; |
77 | } |
78 | |
79 | void StepVisual_TextLiteral::SetPath(const StepVisual_TextPath aPath) |
80 | { |
81 | path = aPath; |
82 | } |
83 | |
84 | StepVisual_TextPath StepVisual_TextLiteral::Path() const |
85 | { |
86 | return path; |
87 | } |
88 | |
89 | void StepVisual_TextLiteral::SetFont(const StepVisual_FontSelect& aFont) |
90 | { |
91 | font = aFont; |
92 | } |
93 | |
94 | StepVisual_FontSelect StepVisual_TextLiteral::Font() const |
95 | { |
96 | return font; |
97 | } |