Trait AnsiStyles

Source
pub trait AnsiStyles {
    // Required methods
    fn header(&self) -> String;
    fn usage(&self) -> String;
    fn literal(&self) -> String;
    fn placeholder(&self) -> String;
    fn error(&self) -> String;
    fn valid(&self) -> String;
    fn invalid(&self) -> String;
}
Expand description

A trait for applying Styles defined in styles to text.

Required Methods§

Source

fn header(&self) -> String

Apply header style to text

Source

fn usage(&self) -> String

Apply usage style to text

Source

fn literal(&self) -> String

Apply literal style to text

Source

fn placeholder(&self) -> String

Apply placeholder style to text

Source

fn error(&self) -> String

Apply error style to text

Source

fn valid(&self) -> String

Apply valid style to text

Source

fn invalid(&self) -> String

Apply invalid style to text

Implementations on Foreign Types§

Source§

impl AnsiStyles for &str

Source§

fn header(&self) -> String

Source§

fn usage(&self) -> String

Source§

fn literal(&self) -> String

Source§

fn placeholder(&self) -> String

Source§

fn error(&self) -> String

Source§

fn valid(&self) -> String

Source§

fn invalid(&self) -> String

Source§

impl AnsiStyles for String

Source§

fn header(&self) -> String

Source§

fn usage(&self) -> String

Source§

fn literal(&self) -> String

Source§

fn placeholder(&self) -> String

Source§

fn error(&self) -> String

Source§

fn valid(&self) -> String

Source§

fn invalid(&self) -> String

Implementors§