pub struct LibraryTokens {
pub star: Color32,
pub star_empty: Color32,
pub pick: Color32,
pub reject: Color32,
pub labels: [Color32; 5],
pub band: Color32,
pub band_outline: Color32,
}Expand description
The library’s content colours, from the installed theme: optional
component tokens (library.*) falling back on system ones, so every
theme draws them without declaring anything. The boxes the marks sit
on (cells, pills, chips, toggles, panes) are the kit’s
(egui_pop_core::kit::Kit: thumb-cell, pill, tag-chip…).
Fields§
§star: Color32A star given (library.star, else status.warning). The rating
stars no longer read it: they are the kit’s rating-star
(egui_pop_core::rating).
star_empty: Color32A pick or reject toggle when off (library.star-empty, else
text.muted); the rating’s empty stars are the kit’s.
pick: Color32The pick flag (library.pick, else text.strong).
reject: Color32The reject mark (library.reject, else status.danger).
labels: [Color32; 5]Red, yellow, green, blue and purple (library.label-<name>).
band: Color32The rubber band (library.band) and its outline.
band_outline: Color32Implementations§
Source§impl LibraryTokens
impl LibraryTokens
pub fn of(ctx: &Context) -> LibraryTokens
Sourcepub fn label(&self, label: ColorLabel) -> Color32
pub fn label(&self, label: ColorLabel) -> Color32
A label’s colour.
Trait Implementations§
Source§impl Clone for LibraryTokens
impl Clone for LibraryTokens
Source§fn clone(&self) -> LibraryTokens
fn clone(&self) -> LibraryTokens
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LibraryTokens
impl Debug for LibraryTokens
Source§impl PartialEq for LibraryTokens
impl PartialEq for LibraryTokens
impl StructuralPartialEq for LibraryTokens
Auto Trait Implementations§
impl Freeze for LibraryTokens
impl RefUnwindSafe for LibraryTokens
impl Send for LibraryTokens
impl Sync for LibraryTokens
impl Unpin for LibraryTokens
impl UnsafeUnpin for LibraryTokens
impl UnwindSafe for LibraryTokens
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
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.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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