Display text
Displays read-only text. You can use it to display static text such as messages.
Data binding
Set or modify the data binding for the view in the General properties tab. Display text can be bound to aString
variable.Configuration properties
Under Configuration, set or modify the appearance and behavior properties for the view. Under Events, set the formula configuration properties.
- Screen size
- A configuration property that has the Screen Sizes icon beside the property name can have different values for each screen size. If you do not set a value, the screen size inherits the value of the next larger screen size as its default value. If you are using the Process Designer desktop editor (deprecated), you are setting the value for the large screen size. The other screen sizes inherit this value.
- Theme definitions
- Theme definitions specify the colors and styles for a view and determine its appearance. You can preview the look and feel of views in the theme editor. See Themes.
The appearance configuration properties for the Display text view are shown in the following table:
Appearance configuration property | Description | Data type |
---|---|---|
Width | The width of the view. You can specify the width in px (pixels), % (percent), or em units. For example, 50px, 20%, or 0.4em. If a unit type is not specified, px is assumed. | String |
Text alignment | The alignment of the display text in relation to the width of the view. | String |
Color style | The color style for the view. This setting applies only to the text, not to the label. The colors correspond to variables in the specified theme. | String |
Size style | The text size. The size applies to both label and text. | String |
Text weight | The text weight. The weight applies only to the text, not to the label. | String |
Label placement | The placement of the label in relation to the text. Labels on the left change the specified width of the view. | String |
Label width | The width of the label. You can specify the width in px (pixels), % (percent), or em units. For example, 50px, 20%, or 0.4em. If a unit type is not specified, px is assumed. | String |
Wrap text | Wraps the display text to a new line. | Boolean |
Behavior configuration property | Description | Data type |
---|---|---|
Allow HTML | Displays the bound data as HTML formatted text. | Boolean |
Example
In this example, the display text is bound to a string that has the following value: "Important information"
The following appearance configuration properties are set for the Display text view:
- Text alignment is set to Left.
- Color style is set to Primary.
- Size style is set to Larger.
- Text weight is set to Slim.
- Label placement is set to Top.
In the General properties tab, the name given to the Label is Welcome.
These properties and their values result in a left-aligned text area that displays larger-sized header labeled Welcome, above the message Important information, in blue, slim and larger-sized font.
Events
Set or modify the formula configuration properties and the event handlers for the view in the Events properties. You can set events to be triggered programmatically or when a user interacts with the view. For information on how to define and code events, see User-defined events.Formula configuration property | Description | Data type |
---|---|---|
Text formula | The formula or expression that is used to calculate the display text. For example, you can specify the Display text value here using quotes, without needing to set a bound variable. For more information about formulas, see Formulas. |
String |
- On load: Activated when the page loads.
Depending on the specific event, you can use JavaScript logic to modify the effects of the view. More information on using events with views is found in the topic Event Handling.
Methods
For detailed information on the available methods for Display text, see the Display text JavaScript API.
Additional resources
For
information about how to create a coach, see Building coaches.
For information about
standard properties (General, Configuration, Positioning, Visibility,
and HTML Attributes), see View properties.