TGML Text Flow: <TextBox>
Text defines a graphics element consisting of text. TextBox wraps the text within the specified box. The TextBox element also supports manual line breaks (ASCII character 10).
The text is stored in the CDATA section of the TextBox element.
Attribute | Type | Description |
---|---|---|
Content |
String |
The character data. |
FontFamily |
String |
The name of the font or font family. |
FontSize |
Double |
The size of the font, in device independent pixels. For more information, see the TGML Coordinate System section. |
FontStyle |
FontStyle |
The style of the font, that is, Normal or Italic. |
FontWeight |
FontWeight |
The style of the font, that is, Normal or Bold. |
HorizontalAlign |
HorizontalAlign |
Describes the horizontal alignment of a text string: |
Left |
Double |
The x coordinate of the upper left corner of the text area. |
Opacity |
Double |
A value between "0.0" (transparent) and "1.0" (opaque) |
Stroke |
Brush |
Describes how the line is painted. |
TextDecoration |
TextDecoration |
Specifies decorations that are added to the text. |
Top |
Double |
The y coordinate of the upper left corner of the text area. |
VerticalAlign |
VerticalAlign |
Describes the vertical alignment of a text string: |
Visibility |
Visibility |
Specifies if the text is visible or not. |
Height |
Double |
The height of the text area. |
Width |
Double |
The width of the text area. |
Example:
<TextBox Left="50" Top="50 Width="200" Height="200">
<![CDATA [This is
three lines
of text]]>
</TextBox>
Example on screen: