pub enum SimpleColor {
Default,
Standard(u8),
EightBit(u8),
Rgb {
r: u8,
g: u8,
b: u8,
},
}Expand description
Simple color enum for backward compatibility.
This is kept for compatibility with existing style.rs code.
For new code, use the full Color struct via Color::parse().
Variants§
Default
Default terminal color (no color set).
Standard(u8)
Standard ANSI color (0-15).
EightBit(u8)
8-bit color (0-255).
Rgb
24-bit RGB color.
Implementations§
Source§impl SimpleColor
impl SimpleColor
Trait Implementations§
Source§impl Clone for SimpleColor
impl Clone for SimpleColor
Source§fn clone(&self) -> SimpleColor
fn clone(&self) -> SimpleColor
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 SimpleColor
impl Debug for SimpleColor
Source§impl Default for SimpleColor
impl Default for SimpleColor
Source§fn default() -> SimpleColor
fn default() -> SimpleColor
Returns the “default value” for a type. Read more
Source§impl From<Color> for SimpleColor
impl From<Color> for SimpleColor
Source§impl From<SimpleColor> for Color
impl From<SimpleColor> for Color
Source§fn from(simple: SimpleColor) -> Self
fn from(simple: SimpleColor) -> Self
Converts to this type from the input type.
Source§impl PartialEq for SimpleColor
impl PartialEq for SimpleColor
impl Copy for SimpleColor
impl Eq for SimpleColor
impl StructuralPartialEq for SimpleColor
Auto Trait Implementations§
impl Freeze for SimpleColor
impl RefUnwindSafe for SimpleColor
impl Send for SimpleColor
impl Sync for SimpleColor
impl Unpin for SimpleColor
impl UnwindSafe for SimpleColor
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.