pub enum FourBitColor {
Show 16 variants
Black,
Red,
Green,
Yellow,
Blue,
Magenta,
Cyan,
White,
Gray,
BrightRed,
BrightGreen,
BrightYellow,
BrightBlue,
BrightMagenta,
BrightCyan,
BrightWhite,
}Expand description
Only use this if you want older system support
Variants§
Black
Red
Green
Yellow
Blue
Magenta
Cyan
White
Gray
BrightRed
BrightGreen
BrightYellow
BrightBlue
BrightMagenta
BrightCyan
BrightWhite
Trait Implementations§
Source§impl Clone for FourBitColor
impl Clone for FourBitColor
Source§fn clone(&self) -> FourBitColor
fn clone(&self) -> FourBitColor
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FourBitColor
impl Debug for FourBitColor
Source§impl Display for FourBitColor
impl Display for FourBitColor
Source§impl DisplayColor for FourBitColor
impl DisplayColor for FourBitColor
Source§fn fmt_background(&self, f: &mut Formatter<'_>) -> Result
fn fmt_background(&self, f: &mut Formatter<'_>) -> Result
Formats the ansi escape code for the background
On the True Color and Eight Bit it will be the Format
\x1b[48;{}m on the four bit it will use the \x1b[{}m Read moreSource§fn fmt_color(&self, f: &mut Formatter<'_>) -> Result
fn fmt_color(&self, f: &mut Formatter<'_>) -> Result
Formats the ansi escape code for the normal color
On the True Color and Eight Bit it will be the Format
\x1b[38;{}m on the four bit it will use the \x1b[{}m Read moreSource§fn background_color(&self) -> String
fn background_color(&self) -> String
Creates the ANSI escape code as a string
Source§impl From<FourBitColor> for Color
impl From<FourBitColor> for Color
Source§fn from(color: FourBitColor) -> Self
fn from(color: FourBitColor) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for FourBitColor
impl RefUnwindSafe for FourBitColor
impl Send for FourBitColor
impl Sync for FourBitColor
impl Unpin for FourBitColor
impl UnwindSafe for FourBitColor
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