Enum Styles

Source
pub enum Styles {
Show 81 variants AlignContent(AlignContent), AlignItems(AlignItems), AlignSelf(AlignSelf), AspectRatio(Number), BackfaceVisibility(BackfaceVisibility), BackgroundColor(Color), BorderColor(Color), BorderEndColor(Color), BorderBottomColor(Color), BorderLeftColor(Color), BorderRightColor(Color), BorderTopColor(Color), BorderStartColor(Color), BorderStyle(BorderStyle), BorderEndStyle(BorderStyle), BorderBottomStyle(BorderStyle), BorderLeftStyle(BorderStyle), BorderRightStyle(BorderStyle), BorderTopStyle(BorderStyle), BorderStartStyle(BorderStyle), BorderWidth(f32), BorderEndWidth(f32), BorderBottomWidth(f32), BorderLeftWidth(f32), BorderRightWidth(f32), BorderTopWidth(f32), BorderStartWidth(f32), BorderRadius(f32), BorderBottomEndRadius(f32), BorderBottomLeftRadius(f32), BorderBottomRightRadius(f32), BorderBottomStartRadius(f32), BorderTopLeftRadius(f32), BorderTopRightRadius(f32), BorderTopEndRadius(f32), BorderTopStartRadius(f32), Bottom(f32), Direction(Direction), Display(Display), End(f32), FlexBasis(f32), FlexDirection(FlexDirection), FlexGrow(f32), FlexShrink(f32), FlexWrap(FlexWrap), FontFamily(FontFamily), FontLineHeight(f32), FontSize(f32), FontStyle(FontStyle), FontWeight(FontWeight), Height(f32), JustifyContent(JustifyContent), Left(f32), MarginBottom(f32), MarginEnd(f32), MarginLeft(f32), MarginRight(f32), MarginStart(f32), MarginTop(f32), MaxHeight(f32), MaxWidth(f32), MinHeight(f32), MinWidth(f32), Opacity(f32), Overflow(Overflow), PaddingBottom(f32), PaddingEnd(f32), PaddingLeft(f32), PaddingRight(f32), PaddingStart(f32), PaddingTop(f32), PositionType(PositionType), Right(f32), Start(f32), TextAlignment(TextAlignment), TextColor(Color), TextDecorationColor(Color), TextShadowColor(Color), TintColor(Color), Top(f32), Width(f32),
}
Expand description

These exist purely for use in the parser code.

A Style is what’s used for a node; Styles are what’s parsed and stored. At render-time, the rendering engine takes n styles and reduces them down into 1 Style that’s applied to the node in question.

Variants§

§

AlignContent(AlignContent)

§

AlignItems(AlignItems)

§

AlignSelf(AlignSelf)

§

AspectRatio(Number)

§

BackfaceVisibility(BackfaceVisibility)

§

BackgroundColor(Color)

§

BorderColor(Color)

§

BorderEndColor(Color)

§

BorderBottomColor(Color)

§

BorderLeftColor(Color)

§

BorderRightColor(Color)

§

BorderTopColor(Color)

§

BorderStartColor(Color)

§

BorderStyle(BorderStyle)

§

BorderEndStyle(BorderStyle)

§

BorderBottomStyle(BorderStyle)

§

BorderLeftStyle(BorderStyle)

§

BorderRightStyle(BorderStyle)

§

BorderTopStyle(BorderStyle)

§

BorderStartStyle(BorderStyle)

§

BorderWidth(f32)

§

BorderEndWidth(f32)

§

BorderBottomWidth(f32)

§

BorderLeftWidth(f32)

§

BorderRightWidth(f32)

§

BorderTopWidth(f32)

§

BorderStartWidth(f32)

§

BorderRadius(f32)

§

BorderBottomEndRadius(f32)

§

BorderBottomLeftRadius(f32)

§

BorderBottomRightRadius(f32)

§

BorderBottomStartRadius(f32)

§

BorderTopLeftRadius(f32)

§

BorderTopRightRadius(f32)

§

BorderTopEndRadius(f32)

§

BorderTopStartRadius(f32)

§

Bottom(f32)

§

Direction(Direction)

§

Display(Display)

§

End(f32)

§

FlexBasis(f32)

§

FlexDirection(FlexDirection)

§

FlexGrow(f32)

§

FlexShrink(f32)

§

FlexWrap(FlexWrap)

§

FontFamily(FontFamily)

§

FontLineHeight(f32)

§

FontSize(f32)

§

FontStyle(FontStyle)

§

FontWeight(FontWeight)

§

Height(f32)

§

JustifyContent(JustifyContent)

§

Left(f32)

§

MarginBottom(f32)

§

MarginEnd(f32)

§

MarginLeft(f32)

§

MarginRight(f32)

§

MarginStart(f32)

§

MarginTop(f32)

§

MaxHeight(f32)

§

MaxWidth(f32)

§

MinHeight(f32)

§

MinWidth(f32)

§

Opacity(f32)

§

Overflow(Overflow)

§

PaddingBottom(f32)

§

PaddingEnd(f32)

§

PaddingLeft(f32)

§

PaddingRight(f32)

§

PaddingStart(f32)

§

PaddingTop(f32)

§

PositionType(PositionType)

§

Right(f32)

§

Start(f32)

§

TextAlignment(TextAlignment)

§

TextColor(Color)

§

TextDecorationColor(Color)

§

TextShadowColor(Color)

§

TintColor(Color)

§

Top(f32)

§

Width(f32)

Trait Implementations§

Source§

impl Debug for Styles

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl Freeze for Styles

§

impl RefUnwindSafe for Styles

§

impl Send for Styles

§

impl Sync for Styles

§

impl Unpin for Styles

§

impl UnwindSafe for Styles

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.