pub struct KitTheme {Show 19 fields
pub backdrop: Color,
pub surface: Color,
pub raised: Color,
pub header: Color,
pub ink: Color,
pub muted: Color,
pub disabled: Color,
pub accent: Color,
pub accent_ink: Color,
pub success: Color,
pub warning: Color,
pub danger: Color,
pub focus: Color,
pub line: Color,
pub shadow: Color,
pub radius: f32,
pub body: f32,
pub title: f32,
pub alpha: f32,
}Expand description
Colors and sizes for kit widgets. alpha multiplies everything, which is
how fades from Appearance are applied (KitTheme::faded).
use ferravex_play::ui::theme::{ThemeMode, UiTheme};
use ferravex_render::ui::kit::KitTheme;
let theme = KitTheme::from_ui_theme(UiTheme::preset(ThemeMode::HighContrast));
assert_eq!(theme.faded(0.5).alpha, 0.5);Fields§
§backdrop: Color§surface: Color§raised: Color§header: Color§ink: Color§muted: Color§disabled: Color§accent: Color§accent_ink: ColorText on an accent fill.
success: Color§warning: Color§danger: Color§focus: Color§line: Color§shadow: Color§radius: f32§body: f32Modern text size for labels and body copy.
title: f32Modern text size for titles.
alpha: f32Implementations§
Trait Implementations§
impl Copy for KitTheme
impl StructuralPartialEq for KitTheme
Auto Trait Implementations§
impl Freeze for KitTheme
impl RefUnwindSafe for KitTheme
impl Send for KitTheme
impl Sync for KitTheme
impl Unpin for KitTheme
impl UnwindSafe for KitTheme
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