[−][src]Struct termion::color::AnsiValue
An arbitrary ANSI color value.
Implementations
impl AnsiValue
[src]
pub fn rgb(r: u8, g: u8, b: u8) -> AnsiValue
[src]
216-color (r, g, b ≤ 5) RGB.
pub fn grayscale(shade: u8) -> AnsiValue
[src]
Grayscale color.
There are 24 shades of gray.
impl AnsiValue
[src]
pub fn fg_string(self) -> String
[src]
Returns the ANSI sequence as a string.
pub fn bg_string(self) -> String
[src]
Returns the ANSI sequence as a string.
Trait Implementations
impl Clone for AnsiValue
[src]
impl Color for AnsiValue
[src]
fn write_fg(&self, f: &mut Formatter<'_>) -> Result
[src]
fn write_bg(&self, f: &mut Formatter<'_>) -> Result
[src]
impl Copy for AnsiValue
[src]
impl Debug for AnsiValue
[src]
Auto Trait Implementations
impl RefUnwindSafe for AnsiValue
[src]
impl Send for AnsiValue
[src]
impl Sync for AnsiValue
[src]
impl Unpin for AnsiValue
[src]
impl UnwindSafe for AnsiValue
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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.
pub 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>,