Rich Text

The RichText widget is used to display text with multiple styles and colors in a single paragraph. It allows you to customize different sections of your text separately, such as changing the color and font size or even adding actions.

You could use this widget to create more visually interesting and engaging text that are sure to capture the attention of your users! For example, a news app that displays articles with rich text formatting such as bold, italics, underlined, different font sizes, and colors.

Adding RichText widget

To add the RichText widget:

  1. Select the RichText widget from the Add Widget Button or add it directly from the widget tree.

  2. By default, it does not add any TextSpan (a section of a text) widget; to add one, click on Add Data under Text Spans.

  3. To stylize any TextSpan, select the Span dropdown and add the Text you want to add (Note: You can also fetch this Text from an API Call).

  4. To customize the TextSpan, click on Text Span Style Properties and customize the values.

Similar to Text Widget, you can also customize the following properties:

Max Lines

Here are the instructions for setting the max lines.

Text Overflow

Here are the instructions for setting Text Overflow.

Text Alignment

Here are the instructions for aligning the Text.

Text Span Style Properties

Here are the instructions for changing Text Span Style Properties.

Customizing

The Widget Properties can be used to customize the appearance and behavior of your widget. View details for Widget's Default Properties here.

Event Handlers

View details for handling events here.

Last updated