Trait vizia_core::modifiers::TextModifiers
source · pub trait TextModifiers: Modifiable {
Show 15 methods
// Provided methods
fn text<T: ToStringLocalized>(self, value: impl Res<T>) -> Self { ... }
fn font_family<U: Into<Vec<FamilyOwned>>>(self, value: impl Res<U>) -> Self { ... }
fn font_weight<U: Into<FontWeight>>(self, value: impl Res<U>) -> Self { ... }
fn font_slant<U: Into<FontSlant>>(self, value: impl Res<U>) -> Self { ... }
fn font_width<U: Into<FontWidth>>(self, value: impl Res<U>) -> Self { ... }
fn font_variation_settings<U: Into<Vec<FontVariation>>>(
self,
value: impl Res<U>,
) -> Self { ... }
fn color<U: Clone + Into<Color>>(self, value: impl Res<U>) -> Self { ... }
fn font_size<U: Into<FontSize>>(self, value: impl Res<U>) -> Self { ... }
fn caret_color<U: Into<Color>>(self, value: impl Res<U>) -> Self { ... }
fn selection_color<U: Into<Color>>(self, value: impl Res<U>) -> Self { ... }
fn text_wrap<U: Into<bool>>(self, value: impl Res<U>) -> Self { ... }
fn text_align<U: Into<TextAlign>>(self, value: impl Res<U>) -> Self { ... }
fn text_overflow<U: Into<TextOverflow>>(self, value: impl Res<U>) -> Self { ... }
fn line_clamp<U: Into<LineClamp>>(self, value: impl Res<U>) -> Self { ... }
fn text_decoration_line<U: Into<TextDecorationLine>>(
self,
value: impl Res<U>,
) -> Self { ... }
}
Expand description
Modifiers for changing the text properties of a view.
Provided Methods§
sourcefn text<T: ToStringLocalized>(self, value: impl Res<T>) -> Self
fn text<T: ToStringLocalized>(self, value: impl Res<T>) -> Self
Sets the text content of the view.
sourcefn font_family<U: Into<Vec<FamilyOwned>>>(self, value: impl Res<U>) -> Self
fn font_family<U: Into<Vec<FamilyOwned>>>(self, value: impl Res<U>) -> Self
Sets the font that should be used by the view.
The font name refers to the name assigned when the font is added to context.
sourcefn font_weight<U: Into<FontWeight>>(self, value: impl Res<U>) -> Self
fn font_weight<U: Into<FontWeight>>(self, value: impl Res<U>) -> Self
Sets the font weight that should be used by the view.
sourcefn font_slant<U: Into<FontSlant>>(self, value: impl Res<U>) -> Self
fn font_slant<U: Into<FontSlant>>(self, value: impl Res<U>) -> Self
Sets the font style that should be used by the view.
sourcefn font_width<U: Into<FontWidth>>(self, value: impl Res<U>) -> Self
fn font_width<U: Into<FontWidth>>(self, value: impl Res<U>) -> Self
Sets the font stretch that should be used by the view if the font supports it.
sourcefn font_variation_settings<U: Into<Vec<FontVariation>>>(
self,
value: impl Res<U>,
) -> Self
fn font_variation_settings<U: Into<Vec<FontVariation>>>( self, value: impl Res<U>, ) -> Self
Sets the font variation settings that should be used by the view.
sourcefn color<U: Clone + Into<Color>>(self, value: impl Res<U>) -> Self
fn color<U: Clone + Into<Color>>(self, value: impl Res<U>) -> Self
Sets the text color of the view.
sourcefn font_size<U: Into<FontSize>>(self, value: impl Res<U>) -> Self
fn font_size<U: Into<FontSize>>(self, value: impl Res<U>) -> Self
Sets the font size of the view.
sourcefn caret_color<U: Into<Color>>(self, value: impl Res<U>) -> Self
fn caret_color<U: Into<Color>>(self, value: impl Res<U>) -> Self
Sets the ext caret color of the view.
sourcefn selection_color<U: Into<Color>>(self, value: impl Res<U>) -> Self
fn selection_color<U: Into<Color>>(self, value: impl Res<U>) -> Self
Sets the color used to highlight selected text within the view.
sourcefn text_wrap<U: Into<bool>>(self, value: impl Res<U>) -> Self
fn text_wrap<U: Into<bool>>(self, value: impl Res<U>) -> Self
Sets whether the text of the view should be allowed to wrap.
sourcefn text_align<U: Into<TextAlign>>(self, value: impl Res<U>) -> Self
fn text_align<U: Into<TextAlign>>(self, value: impl Res<U>) -> Self
Sets the horizontal alignment of text within the view.
sourcefn text_overflow<U: Into<TextOverflow>>(self, value: impl Res<U>) -> Self
fn text_overflow<U: Into<TextOverflow>>(self, value: impl Res<U>) -> Self
Sets the text overflow.
sourcefn line_clamp<U: Into<LineClamp>>(self, value: impl Res<U>) -> Self
fn line_clamp<U: Into<LineClamp>>(self, value: impl Res<U>) -> Self
Sets the max number of .
sourcefn text_decoration_line<U: Into<TextDecorationLine>>(
self,
value: impl Res<U>,
) -> Self
fn text_decoration_line<U: Into<TextDecorationLine>>( self, value: impl Res<U>, ) -> Self
Sets the max number of .