pub struct StateStyle {
pub background: Option<Color>,
pub foreground: Option<Color>,
pub border_color: Option<Color>,
pub border_width: Option<u8>,
pub font: Option<TextStyle>,
}Expand description
Look overrides for one visual state. A field left None is not overridden: it falls back to
the normal style, and then to the Widget’s built-in default.
Fields§
§background: Option<Color>The background fill color.
foreground: Option<Color>The text (foreground) color.
border_color: Option<Color>The border color.
border_width: Option<u8>The border width in pixels.
font: Option<TextStyle>The font, size, and alignment of the text.
Implementations§
Source§impl StateStyle
impl StateStyle
Sourcepub fn or(self, fallback: &StateStyle) -> StateStyle
pub fn or(self, fallback: &StateStyle) -> StateStyle
Trait Implementations§
Source§impl Clone for StateStyle
impl Clone for StateStyle
Source§impl Debug for StateStyle
impl Debug for StateStyle
Source§impl Default for StateStyle
impl Default for StateStyle
Source§impl PartialEq for StateStyle
impl PartialEq for StateStyle
impl StructuralPartialEq for StateStyle
Auto Trait Implementations§
impl Freeze for StateStyle
impl RefUnwindSafe for StateStyle
impl Send for StateStyle
impl Sync for StateStyle
impl Unpin for StateStyle
impl UnsafeUnpin for StateStyle
impl UnwindSafe for StateStyle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more