pub enum ColorSpec {
Default,
PaletteIndex(PaletteIndex),
TrueColor(SrgbaTuple),
}
Expand description
Specifies the color to be used when rendering a cell.
This differs from ColorAttribute
in that this type can only
specify one of the possible color types at once, whereas the
ColorAttribute
type can specify a TrueColor value and a fallback.
Variants
Default
PaletteIndex(PaletteIndex)
Use either a raw number, or use values from the AnsiColor
enum
TrueColor(SrgbaTuple)
Trait Implementations
sourceimpl From<ColorSpec> for ColorAttribute
impl From<ColorSpec> for ColorAttribute
sourceimpl From<SrgbaTuple> for ColorSpec
impl From<SrgbaTuple> for ColorSpec
sourcefn from(col: SrgbaTuple) -> Self
fn from(col: SrgbaTuple) -> Self
Converts to this type from the input type.
impl Copy for ColorSpec
impl Eq for ColorSpec
impl StructuralEq for ColorSpec
impl StructuralPartialEq for ColorSpec
Auto Trait Implementations
impl RefUnwindSafe for ColorSpec
impl Send for ColorSpec
impl Sync for ColorSpec
impl Unpin for ColorSpec
impl UnwindSafe for ColorSpec
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more