[−][src]Struct polyhorn_ui::styles::TextStyle
Controls the appearance of a Text.
Fields
color: Inherited<Color>
This is the color that will be used to fill the text outlines. If not
present, the Text component will inherit the text color of its parent.
If the parent does not have a color, the default Color::canvastext()
system color will be used. Note that the concrete value of this color
is system-dependent and can vary depending on the user's appearance mode
(i.e. light vs. dark mode).
font_family: Inherited<FontFamily<S>>
This is the font family that will be used to render the text outlines.
If not present, the Text component will inherit its font family from its
parent. If the parent does not have a font family, the default
FontFamily::Generic(GenericFontFamily::SansSerif)
will be used. Note
that the concrete value of this font family is system-dependent and can
vary depending on the user's preferred fonts.
font_weight: Inherited<FontWeight>
This is the font weight that will be used to render the text outlines.
If not present, the Text component will inherit its font weight from its
parent. If the parent does not have a font weight, the default
FontWeight::Normal
(400) will be used.
font_style: Inherited<FontStyle>
This is the font style that will be used to render the text outlines. If
not present, the Text component will inherit its font style from its
parent. If the parent does not have a font style, the default
FontStyle::Normal
will be used.
font_size: Inherited<FontSize>
This is the font size that will be used to render the text. If not
present, the Text component will inherit its font size from its parent.
If the parent does not have a font size, the default FontSize:Medium
will be used. Note that the concrete value of this font size is
system-dependent and can vary depending on a user's preferred font size.
text_align: Inherited<TextAlign>
Controls the alignment of text when it is rendered to a container that is larger than the rendered text.
Trait Implementations
impl<S: Clone> Clone for TextStyle<S>
[src]
impl<S: Copy> Copy for TextStyle<S>
[src]
impl<S: Debug> Debug for TextStyle<S>
[src]
impl<S: Default> Default for TextStyle<S>
[src]
impl<S: PartialEq> PartialEq<TextStyle<S>> for TextStyle<S>
[src]
impl<S> StructuralPartialEq for TextStyle<S>
[src]
Auto Trait Implementations
impl<S> RefUnwindSafe for TextStyle<S> where
S: RefUnwindSafe,
S: RefUnwindSafe,
impl<S> Send for TextStyle<S> where
S: Send,
S: Send,
impl<S> Sync for TextStyle<S> where
S: Sync,
S: Sync,
impl<S> Unpin for TextStyle<S> where
S: Unpin,
S: Unpin,
impl<S> UnwindSafe for TextStyle<S> where
S: UnwindSafe,
S: UnwindSafe,
Blanket Implementations
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
[src]
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
[src]
M: TransformMatrix<Swp, Dwp, T>,
fn adapt_into(self) -> D
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> ConvertInto<U> for T where
U: ConvertFrom<T>,
[src]
U: ConvertFrom<T>,
fn convert_into(self) -> U
[src]
fn convert_unclamped_into(self) -> U
[src]
fn try_convert_into(self) -> Result<U, OutOfBounds<U>>
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,