pub trait Fmt: Sized {
// Provided methods
fn fg<C: Into<Option<Color>>>(self, color: C) -> Foreground<Self>
where Self: Display { ... }
fn bg<C: Into<Option<Color>>>(self, color: C) -> Background<Self>
where Self: Display { ... }
}
Expand description
A trait used to add formatting attributes to displayable items.
If using the concolor
feature, this trait assumes that the items are going to be printed to
stderr
. If you are printing to stdout
, use
the StdoutFmt
trait instead.
Attributes specified through this trait are not composable (i.e: the behaviour of two nested attributes each with a conflicting attribute is left unspecified).
Provided Methods§
Object Safety§
This trait is not object safe.