pub struct DecorativeColors {
pub red: Color,
pub orange: Color,
pub amber: Color,
pub green: Color,
pub teal: Color,
pub cyan: Color,
pub blue: Color,
pub violet: Color,
pub magenta: Color,
}Expand description
Vibrant categorical source colors with matched OKLCH lightness and chroma, so no hue shouts over another.
Fields§
§red: Color§orange: Color§amber: Color§green: Color§teal: Color§cyan: Color§blue: Color§violet: Color§magenta: ColorImplementations§
Source§impl DecorativeColors
impl DecorativeColors
Sourcepub fn light() -> DecorativeColors
pub fn light() -> DecorativeColors
Light-surface decorative set. Every hue except amber reaches at least 3:1 against white; derived text roles cover the rest.
Sourcepub fn dark() -> DecorativeColors
pub fn dark() -> DecorativeColors
Dark-surface decorative set, lifted so every hue reads at least 6.5:1 on the dark panel.
pub fn get(&self, hue: DecorativeHue) -> Color
pub fn set(&mut self, hue: DecorativeHue, color: Color)
Trait Implementations§
Source§impl Clone for DecorativeColors
impl Clone for DecorativeColors
Source§fn clone(&self) -> DecorativeColors
fn clone(&self) -> DecorativeColors
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for DecorativeColors
Source§impl Debug for DecorativeColors
impl Debug for DecorativeColors
Source§impl PartialEq for DecorativeColors
impl PartialEq for DecorativeColors
impl StructuralPartialEq for DecorativeColors
Auto Trait Implementations§
impl Forget for DecorativeColors
impl Freeze for DecorativeColors
impl Move for DecorativeColors
impl RefUnwindSafe for DecorativeColors
impl Send for DecorativeColors
impl Sync for DecorativeColors
impl Unpin for DecorativeColors
impl UnsafeUnpin for DecorativeColors
impl UnwindSafe for DecorativeColors
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.