pub enum CommonColor {
Show 28 variants
Off,
DarkGray,
LightGray,
White,
DimRed,
NormalRed,
BrightRed,
DimOrange,
NormalOrange,
BrightOrange,
DimYellow,
NormalYellow,
BrightYellow,
DimGreen,
NormalGreen,
BrightGreen,
DimCyan,
NormalCyan,
BrightCyan,
DimBlue,
NormalBlue,
BrightBlue,
DimPurple,
NormalPurple,
BrightPurple,
DimPink,
NormalPink,
BrightPink,
}Expand description
Enum representing a set of common named colors supported by the Launchkey palette. These are mapped to fixed RGB values and palette indices.
Variants§
Off
DarkGray
LightGray
White
DimRed
NormalRed
BrightRed
DimOrange
NormalOrange
BrightOrange
DimYellow
NormalYellow
BrightYellow
DimGreen
NormalGreen
BrightGreen
DimCyan
NormalCyan
BrightCyan
DimBlue
NormalBlue
BrightBlue
DimPurple
NormalPurple
BrightPurple
DimPink
NormalPink
BrightPink
Implementations§
Source§impl CommonColor
impl CommonColor
Sourcepub fn to_palette_index(self) -> ColorPaletteIndex
pub fn to_palette_index(self) -> ColorPaletteIndex
Converts the CommonColor to a ColorPaletteIndex.
Sourcepub fn to_color(self) -> Color
pub fn to_color(self) -> Color
Converts the CommonColor to a Color.
Trait Implementations§
Source§impl Clone for CommonColor
impl Clone for CommonColor
Source§fn clone(&self) -> CommonColor
fn clone(&self) -> CommonColor
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 CommonColor
impl Debug for CommonColor
Source§impl Into<Color> for CommonColor
impl Into<Color> for CommonColor
Source§impl Into<ColorPaletteIndex> for CommonColor
impl Into<ColorPaletteIndex> for CommonColor
Source§fn into(self) -> ColorPaletteIndex
fn into(self) -> ColorPaletteIndex
Converts this type into the (usually inferred) input type.
Source§impl PartialEq for CommonColor
impl PartialEq for CommonColor
impl Copy for CommonColor
impl Eq for CommonColor
impl StructuralPartialEq for CommonColor
Auto Trait Implementations§
impl Freeze for CommonColor
impl RefUnwindSafe for CommonColor
impl Send for CommonColor
impl Sync for CommonColor
impl Unpin for CommonColor
impl UnwindSafe for CommonColor
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more