[−][src]Struct kas_theme::ThemeColours
Provides standard theme colours
Fields
background: Colour
Background colour
frame: Colour
Colour for frames (not always used)
bg: Colour
Background colour of EditBox
bg_disabled: Colour
Background colour of EditBox
(disabled state)
bg_error: Colour
Background colour of EditBox
(error state)
text: Colour
Text colour in an EditBox
text_sel: Colour
Selected tect colour
text_sel_bg: Colour
Selected text background colour
label_text: Colour
Text colour in a Label
Text colour on a TextButton
Highlight colour for keyboard navigation
Colour of a TextButton
Colour of a TextButton
(disabled state)
Colour of a TextButton
when hovered by the mouse
Colour of a TextButton
when depressed
checkbox: Colour
Colour of mark within a CheckBox
or RadioBox
Implementations
impl ThemeColours
[src]
pub fn open(scheme: &str) -> Option<Self>
[src]
Open the given scheme, if found
TODO: the intention is that this method can read and cache data from external resources. For now, we simply hard-code a few instances.
pub fn new() -> Self
[src]
Default theme: white with blue activable items
pub fn grey() -> Self
[src]
Grey with blue activable items
pub fn light() -> Self
[src]
Light scheme
pub fn dark() -> Self
[src]
Dark scheme
pub fn bg_col(&self, state: InputState) -> Colour
[src]
Get colour of a text area, depending on state
pub fn nav_region(&self, state: InputState) -> Option<Colour>
[src]
Get colour for navigation highlight region, if any
pub fn button_state(&self, state: InputState) -> Colour
[src]
Get colour for a button, depending on state
pub fn check_mark_state(
&self,
state: InputState,
checked: bool
) -> Option<Colour>
[src]
&self,
state: InputState,
checked: bool
) -> Option<Colour>
Get colour for a checkbox mark, depending on state
pub fn menu_entry(&self, state: InputState) -> Option<Colour>
[src]
Get background highlight colour of a menu entry, if any
pub fn scrollbar_state(&self, state: InputState) -> Colour
[src]
Get colour of a scrollbar, depending on state
pub fn text_class(&self, class: TextClass) -> Colour
[src]
Get text colour from class
Trait Implementations
impl Clone for ThemeColours
[src]
pub fn clone(&self) -> ThemeColours
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for ThemeColours
[src]
Auto Trait Implementations
impl RefUnwindSafe for ThemeColours
impl Send for ThemeColours
impl Sync for ThemeColours
impl Unpin for ThemeColours
impl UnwindSafe for ThemeColours
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,
pub 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.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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.
pub 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>,