[−][src]Enum anes::Color
A color.
This is NOT a full ANSI sequence. Color
must be used along with
the:
Examples
use std::io::{stdout, Write}; use anes::{Color, SetForegroundColor}; let mut stdout = stdout(); // Set the foreground color to red write!(stdout, "{}", SetForegroundColor(Color::Red));
Variants
Default color.
Black color.
Dark red color.
Dark green color.
Dark yellow color.
Dark blue color.
Dark magenta color.
Dark cyan color.
Dark gray color.
Also knows as light (bright) black.
Light (bright) gray color.
Also known as dark white.
Light (bright) red color.
Light (bright) green color.
Light (bright) yellow color.
Light (bright) blue color.
Light (bright) magenta color.
Light (bright) cyan color.
White color.
Ansi(u8)
A color from the predefined set of ANSI colors.
0 - 7: standard colors (as in ESC [ 30–37 m)
8- 15: high intensity colors (as in ESC [ 90–97 m)
16-231: 6 × 6 × 6 cube (216 colors): 16 + 36 × r + 6 × g + b (0 ≤ r, g, b ≤ 5)
232-255: grayscale from black to white in 24 steps
See 8-bit for more information.
An RGB color.
See 24-bit for more information.
Trait Implementations
impl Clone for Color
[src]
impl Copy for Color
[src]
impl Eq for Color
[src]
impl PartialEq<Color> for Color
[src]
impl Display for Color
[src]
impl Debug for Color
[src]
impl Hash for Color
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl StructuralPartialEq for Color
[src]
impl StructuralEq for Color
[src]
Auto Trait Implementations
impl Send for Color
impl Sync for Color
impl Unpin for Color
impl UnwindSafe for Color
impl RefUnwindSafe for Color
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,