pub struct Palette {Show 14 fields
pub fg: Color,
pub fg_dim: Color,
pub bg: Option<Color>,
pub bg_alt: Option<Color>,
pub accent: Color,
pub accent_dim: Color,
pub success: Color,
pub warning: Color,
pub error: Color,
pub info: Color,
pub border: Color,
pub border_focused: Color,
pub selection_fg: Color,
pub selection_bg: Color,
}Expand description
Semantic colour palette — all theme-dependent colours in one place.
Style methods pull from the active palette rather than hardcoding colours, so a single palette swap re-themes the entire UI.
Fields§
§fg: ColorPrimary text.
fg_dim: ColorSecondary/muted text.
bg: Option<Color>None = inherit terminal background.
bg_alt: Option<Color>Alternate background for contrast (status bar, selections).
accent: ColorPrimary accent (focused borders, highlights).
accent_dim: ColorSubdued accent (unfocused, help text).
success: ColorPass, installed, current.
warning: ColorOutdated, stale, warnings.
error: ColorFailed, drifted, critical violations.
info: ColorInformational, running, in-progress.
border: ColorDefault border colour.
border_focused: ColorFocused panel border.
selection_fg: ColorForeground in selected/highlighted items.
selection_bg: ColorBackground in selected/highlighted items.
Trait Implementations§
impl Eq for Palette
impl StructuralPartialEq for Palette
Auto Trait Implementations§
impl Freeze for Palette
impl RefUnwindSafe for Palette
impl Send for Palette
impl Sync for Palette
impl Unpin for Palette
impl UnsafeUnpin for Palette
impl UnwindSafe for Palette
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
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