pub struct Style {
pub fg: Option<u8>,
pub bg: Option<u8>,
pub dim: bool,
pub bold: bool,
pub italic: bool,
pub underline: bool,
pub blink: bool,
pub inverse: bool,
pub strike: bool,
}Expand description
A minimal style model compatible with classic ANSI SGR.
This intentionally stays small; higher layers can extend or map their own style semantics onto this.
Fields§
§fg: Option<u8>§bg: Option<u8>§dim: boolANSI “faint” (SGR 2). Often rendered as dim/low intensity.
bold: bool§italic: boolANSI italic (SGR 3). Not universally supported, but common in modern terminals.
underline: bool§blink: boolANSI blink (SGR 5). Often disabled by terminals; modeled for completeness.
inverse: boolANSI reverse video (SGR 7).
strike: boolANSI strikethrough (SGR 9).
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Style
impl<'de> Deserialize<'de> for Style
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Copy for Style
impl Eq for Style
impl StructuralPartialEq for Style
Auto Trait Implementations§
impl Freeze for Style
impl RefUnwindSafe for Style
impl Send for Style
impl Sync for Style
impl Unpin for Style
impl UnsafeUnpin for Style
impl UnwindSafe for Style
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