Text Display
The Text Display graphic element is a control to show text or a string tag value. Text Display appears under
CommonControls
in the Toolbox
. Use the Text Display graphic element to:
- Show messages from the data source on the HMI device. For example, set up the data source to generate strings that report on the state of a process or operation, or that provide instructions about what the operator needs to do next.
- Provide descriptive text or labels for other graphic elements on the screen.
Bind the
Text
property to a string tag, a numeric tag, or an expression to display information from the data source. To use the Text Display as a label with static text, enter the static text value in the Text
box.
TIP:
Tips:
- To change theTextproperty value, double-click the Text Display graphic element on the screen to select the text and enter a new value. If the Text Display is bound to a tag or expression, theInitialvalue of theTextbox changes.
- Do not place text against the border of a graphic element. Allow for a small difference in space, such as one or two characters. If you place text against the border of a graphic element, the text may wrap differently or appear clipped on the HMI device.
- The maximum length of a text display reading from a String data type in a controller is 476 characters.
- If the String is encoded using UTF-8, the text display may not show 476 characters because each character may take multiple bytes of data.
- Embedding a REAL tag value in a text display or popup caption shows 13 digits after the decimal point by default. To reduce the number of digits after the decimal point, use a truncate and divide operation. For example, to limit the number of digits shown after the decimal point to 3 digits, use the expression TRUNC(MyTag*10e2)/10e2. To show n+1 digits, use the expression TRUNC(MyTag*10en)/10en.
Built-in animation properties
Built-in animation properties appear under the
General
category of the Properties
window. Specify values for these properties in order to animate the graphic element or change the information the graphic element shows on the HMI device. Name | Category | Purpose | Accepted values |
Text | General | Specifies the text on the graphic element. Do not place text against the border of a graphic element. Allow for a small difference in space, such as one or two characters. If you place text against the border of a graphic element, the text may wrap differently or appear clipped on the HMI device. | Alpha-numeric characters |
Unique properties are properties that not all graphic elements in the
Toolbox
share.Name | Category | Purpose | Accepted values |
CornerRadius | Appearance | Specifies the curve of the corners. | 0 or a positive number |
FillColor | Appearance | Specifies the fill color. | Any selected color in the Color Picker or a Hex color value entered manually. The Hex value must be in the format #RRGGBB. R, G, and B are Hex digits from 0 through F and represent the color channel values for red, green, and blue. For example, #ffff00 produces yellow. |
TextAlignment | Appearance | Specifies the vertical and horizontal alignment of the text. | Vertical alignment:
Horizontal alignment:
|
Color | Appearance/Border | Specifies the color of the border. | Any selected color in the Color Picker or a Hex color value entered manually. The Hex value must be in the format #RRGGBB. R, G, and B are Hex digits from 0 through F and represent the color channel values for red, green, and blue. For example, #ffff00 produces yellow. |
Style | Appearance/Border | Specifies the style of the border line. |
|
Width | Position and Size | Specifies the width in pixels. | Any positive number |
FontName | Appearance | Specifies the font of the text. | Any selected font |
FooterFontColor | Appearance | Specifies the color of the text in the footer. | Any selected color in the Color Picker or a Hex color value entered manually. The Hex value must be in the format #RRGGBB. R, G, and B are Hex digits from 0 through F and represent the color channel values for red, green, and blue. For example, #ffff00 produces yellow. |
FooterFontSize | Appearance | Specifies the size of the text in the footer. | Positive numbers |
Bold | Appearance | Makes the text or value on the graphic element bold. |
|
Underline | Appearance | Make the text underlined. |
|
Padding | Appearance | Specifies the distance, in points, between the content of the element and the edge of the element. | Any numeric value |
Common properties exist for all graphic elements.
Property | Category | Purpose | Accepted Values |
Access | Security | Specifies if all users have access to the control element, or if access is inherited from the screen. |
|
Angle | Position and Size | Specifies the rotation angle. Enter 180 to display the graphic element upside down. If you enter a value larger than 360, the portion of numeric value that is over 360 becomes the value. For example, enter 380 to see a value of 20. If you enter a value less than 0, the negative value is subtracted from 360. For example, enter -30 to see a value of 330. |
|
Enabled | Appearance | Specifies if the graphic element is available on the HMI device and if the graphic element accepts touch and key input. |
|
Height | Position and Size | Specifies the height in pixels. | Any positive numeric value |
Opacity | Appearance | Specifies the transparency of the graphic element. | 0 (fully transparent) - 100 (fully opaque) |
Visible | Appearance | Specifies if the graphic element is visible on the HMI device. |
|
Width | Position and Size | Specifies the width in pixels. | Any positive number |
X | Position and Size | Specifies the horizontal coordinate, in pixels, from the upper left corner of screen to the upper left corner of a graphic element or group with no rotation. If the graphic element or group is rotated, the X property value does not change. | Any positive number |
Y | Position and Size | Specifies the vertical coordinate, in pixels, from the upper left corner of screen to the upper left corner of a graphic element or group with no rotation. If the graphic element or group is rotated, the Y property value does not change. | Any positive number |
Provide Feedback