[−][src]Enum elvis_core::value::Color
Color
system, accroding to material design's color system.
Variants
Color::Inherit => "0xFFFFFFFF"
Color::ORGB => "0xOORRGGBB"
Color::Amber => "0xFFFFC107"
Color::AmberAccent => "0xFFFFD740"
Color::Black => "0xFF000000"
Color::Blue => "0xFF2196F3"
Color::BlueAccent => "0xFF448AFF"
Color::BlueGrey => "0xFF607D8B"
Color::Brown => "0xFF795548"
Color::Cyan => "0xFF00BCD4"
Color::CyanAccent => "0xFF18FFFF"
Color::DeepOrange => "0xFFFF5722"
Color::DeepOrangeAccent => "0xFFFF6E40"
Color::DeepPurple => "0xFF673AB7"
Color::DeepPurpleAccent => "0xFF7C4DFF"
Color::Green => "0xFF4CAF50"
Color::GreenAccent => "0xFF69F0AE"
Color::Grey => "FF9E9E9E"
Color::Indigo => "0xFF3F51B5"
Color::IndigoAccent => "0xFF536DFE"
Color::LightBlue => "0xFF03A9FA"
Color::LightBlueAccent => "0xFF40C4FF"
Color::LightGreen => "0xFF8BC34A"
Color::LightGreenAccent => "0xFFB2FF59"
Color::Lime => "0xFFCDDC39"
Color::LimeAccent => "0xFFEEFF41"
Color::Orange => "0xFFFF9800"
Color::OrangeAccent => "0xFFFFAB40"
Color::Pink => "0xFFE91E63"
Color::PinkAccent => "0xFFFF4081"n
Color::Purple => "0xFF9C27B0"
Color::PurpleAccent => "0xFFE040FB"
Color::Red => "0xFFF44336"
Color::RedAccent => "0xFFFF5252"
Color::Teal => "0xFF009688"
Color::TealAccent => "0xFF64FFDA"
Color::Transparent => "0xFFFFFFFF"
Color::White => "0xFFFFFFFF"
Color::Yellow => "0xFFFFEB3B"
Color::YellowAccent => "0xFFFFFF00"
Implementations
impl Color
[src]
pub fn from_hex(h: String) -> Color
[src]
convert Color
from hex, to specfic color if the hex is in Color
pub fn red(self, red: i16) -> Self
[src]
Set red
pub fn green(self, green: i16) -> Self
[src]
Set green
pub fn blue(self, blue: i16) -> Self
[src]
Set blue
pub fn transparent(self, transparency: f32) -> Self
[src]
Set transparency
pub fn from_hex_to_orgb(h: String) -> Color
[src]
convert hex to Color::ORGB
pub fn to_hex(&self) -> String
[src]
convert Color
to hex string
pub fn to_orgb(&self) -> Color
[src]
convert Color
to Color::ORGB
Trait Implementations
impl Clone for Color
[src]
impl Copy for Color
[src]
impl Debug for Color
[src]
impl Default for Color
[src]
Pink is the Pig
impl Eq for Color
[src]
impl Into<Style> for Color
[src]
impl Ord for Color
[src]
fn cmp(&self, o: &Self) -> Ordering
[src]
#[must_use]fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<Color> for Color
[src]
impl PartialOrd<Color> for Color
[src]
fn partial_cmp(&self, o: &Self) -> Option<Ordering>
[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl ToString for Color
[src]
Auto Trait Implementations
impl RefUnwindSafe for Color
impl Send for Color
impl Sync for Color
impl Unpin for Color
impl UnwindSafe for Color
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,
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.
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>,