pub struct Colors { /* private fields */ }Expand description
ANSI color codes
Implementations§
Source§impl Colors
impl Colors
pub fn new() -> Self
pub const fn bold(self) -> &'static str
pub const fn dim(self) -> &'static str
pub const fn reset(self) -> &'static str
pub const fn red(self) -> &'static str
pub const fn green(self) -> &'static str
pub const fn yellow(self) -> &'static str
pub const fn blue(self) -> &'static str
pub const fn magenta(self) -> &'static str
pub const fn cyan(self) -> &'static str
pub const fn white(self) -> &'static str
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Colors
impl RefUnwindSafe for Colors
impl Send for Colors
impl Sync for Colors
impl Unpin for Colors
impl UnwindSafe for Colors
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more