pub struct Style {
pub fg: Option<Color>,
pub bg: Option<Color>,
pub bold: bool,
pub dim: bool,
pub italic: bool,
pub underline: bool,
pub strikethrough: bool,
pub blink: bool,
pub reset: bool,
}Expand description
A complete set of visual attributes for a span of text.
Fields§
§fg: Option<Color>Foreground color. None leaves the terminal default unchanged.
bg: Option<Color>Background color. None leaves the terminal default unchanged.
bold: boolBold text (SGR 1).
dim: boolReduced intensity text (SGR 2).
italic: boolItalic text (SGR 3).
underline: boolUnderlined text (SGR 4).
strikethrough: boolCrossed-out text (SGR 9).
blink: boolBlinking text (SGR 5). Terminal support varies.
reset: boolFull reset. Enabling this option overrides all previous options.
Implementations§
Trait Implementations§
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