pub fn Text<S>(__arg0: S, __arg1: Modifier, __arg2: TextStyle) -> NodeIdExpand description
High-level element that displays text.
§When to use
Use this widget to display read-only text on the screen. For editable text,
use BasicTextField.
§Arguments
value- The string to display. Can be a&str,String, orState<String>.modifier- Modifiers to apply (e.g., padding, background, layout instructions).style- Text styling (color, font size).
§Example
ⓘ
Text("Hello World", Modifier::padding(16.0), TextStyle::default());