Skip to main content

BasicTextFieldDecorated

Function BasicTextFieldDecorated 

Source
pub fn BasicTextFieldDecorated<D>(
    __arg0: TextFieldState,
    __arg1: Modifier,
    __arg2: BasicTextFieldOptions,
    __arg3: D,
) -> NodeId
where D: Fn(BasicTextFieldDecorationScope) + 'static,
Expand description

Creates an editable field and lets decoration_box place composable labels, placeholders, icons, buttons, prefixes, or suffixes around it.

As in Compose, the decoration box is the field: modifier applies to it, and it takes the field’s pointer input, focus and semantics, so a press anywhere in it edits the text. The inner field only lays out and draws the text, as wide as the text unless the decoration stretches it (a Box that propagates its minimum constraints, for one).