Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
ILayoutElement.cs
1using System;
2using System.Threading.Tasks;
3using System.Xml;
5using Waher.Script;
6
8{
12 public interface ILayoutElement : IDisposable
13 {
18 {
19 get;
20 }
21
26 {
27 get;
28 }
29
33 string LocalName
34 {
35 get;
36 }
37
41 string Namespace
42 {
43 get;
44 }
45
49 float? Left
50 {
51 get;
52 set;
53 }
54
58 float? Right
59 {
60 get;
61 set;
62 }
63
67 float? Top
68 {
69 get;
70 set;
71 }
72
76 float? Bottom
77 {
78 get;
79 set;
80 }
81
85 float? Width
86 {
87 get;
88 set;
89 }
90
94 float? Height
95 {
96 get;
97 set;
98 }
99
104 {
105 get;
106 }
107
112 {
113 get;
114 }
115
120 {
121 get;
122 }
123
128 {
129 get;
130 }
131
136 {
137 get;
138 set;
139 }
140
145 {
146 get;
147 set;
148 }
149
154 {
155 get;
156 }
157
162 {
163 get;
164 }
165
173
178 Task FromXml(XmlElement Input);
179
184 string ToXml();
185
190 void ToXml(XmlWriter Output);
191
198
203 void CopyContents(ILayoutElement Destination);
204
209 Task RegisterIDs(Variables Session);
210
219
225
231
237
243
248 Task Draw(DrawingState State);
249
255
260 string ExportState();
261
266 void ExportState(XmlWriter Output);
267 }
268}
Contains a 2D layout document.
Collection of variables.
Definition: Variables.cs:25
Base interface for all layout elements.
float? Bottom
Bottom coordinate of bounding box, after measurement.
Task RegisterIDs(Variables Session)
Registers any IDs defined with the encapsulating document.
ILayoutElement Copy(ILayoutElement Parent)
Creates a copy of the layout element.
float? Right
Right coordinate of bounding box, after measurement.
Task Draw(DrawingState State)
Draws layout entities.
Task MeasureDimensions(DrawingState State)
Measures layout entities and defines unassigned properties, related to dimensions....
void CopyContents(ILayoutElement Destination)
Copies contents (attributes and children) to the destination element.
float? InnerWidth
Inner Width of element
float? ExplicitHeight
Explicit set height of element, if defined.
void BeforeMeasureDimensions(DrawingState State)
Called before dimensions are measured.
bool IsVisible
If the element is visible or not.
string LocalName
Local name of type of element.
void ToXml(XmlWriter Output)
Exports the element to XML.
Task FromXml(XmlElement Input)
Populates the element (including children) with information from its XML definition.
float? Left
Left coordinate of bounding box, after measurement.
Task DoMeasureDimensions(DrawingState State)
Measures layout entities and defines unassigned properties, related to dimensions.
float? Top
Top coordinate of bounding box, after measurement.
float? PotentialHeight
Potential Height of element
ILayoutElement Create(Layout2DDocument Document, ILayoutElement Parent)
Creates a new instance of the layout element.
string ExportState()
Exports the internal state of the layout.
void MeasurePositions(DrawingState State)
Measures layout entities and defines unassigned properties, related to positions.
ILayoutElement Parent
Parent element.
Task AfterMeasureDimensions(DrawingState State)
Called when dimensions have been measured.
void ExportState(XmlWriter Output)
Exports the internal state of the layout.
float? ExplicitWidth
Explicit set width of element, if defined.
string ToXml()
Exports the element to XML.
string Namespace
Namespace of type of element.
float? PotentialWidth
Potential Width of element
Layout2DDocument Document
Layout document.
StringAttribute IdAttribute
ID Attribute
float? InnerHeight
Inner Height of element
Task DrawShape(DrawingState State)
Draw the shape represented by the layout element.