[][src]Trait crossterm::style::Styler

pub trait Styler<D: Display + Clone> {
    pub fn reset(self) -> StyledContent<D>;
pub fn bold(self) -> StyledContent<D>;
pub fn underlined(self) -> StyledContent<D>;
pub fn reverse(self) -> StyledContent<D>;
pub fn dim(self) -> StyledContent<D>;
pub fn italic(self) -> StyledContent<D>;
pub fn negative(self) -> StyledContent<D>;
pub fn slow_blink(self) -> StyledContent<D>;
pub fn rapid_blink(self) -> StyledContent<D>;
pub fn hidden(self) -> StyledContent<D>;
pub fn crossed_out(self) -> StyledContent<D>; }

Provides a set of methods to set the text attributes.

Method names correspond to the Attribute enum variants.

Examples

use crossterm::style::Styler;

println!("{}", "Bold text".bold());
println!("{}", "Underlined text".underlined());
println!("{}", "Negative text".negative());

Required methods

pub fn reset(self) -> StyledContent<D>[src]

pub fn bold(self) -> StyledContent<D>[src]

pub fn underlined(self) -> StyledContent<D>[src]

pub fn reverse(self) -> StyledContent<D>[src]

pub fn dim(self) -> StyledContent<D>[src]

pub fn italic(self) -> StyledContent<D>[src]

pub fn negative(self) -> StyledContent<D>[src]

pub fn hidden(self) -> StyledContent<D>[src]

pub fn crossed_out(self) -> StyledContent<D>[src]

Loading content...

Implementations on Foreign Types

impl Styler<String> for String[src]

impl Styler<char> for char[src]

impl<'a> Styler<&'a str> for &'a str[src]

Loading content...

Implementors

impl<D: Display + Clone> Styler<D> for StyledContent<D>[src]

Loading content...