Trait kas_theme::ThemeDst[][src]

pub trait ThemeDst<DS: DrawSharedImpl>: ThemeApi {
    fn config(&self) -> MaybeBoxed<'_, dyn Any>;
fn apply_config(&mut self, config: &dyn Any) -> TkAction;
fn init(&mut self, shared: &mut SharedState<DS>);
fn new_window(&self, dpi_factor: f32) -> StackDst<dyn Window>;
fn update_window(&self, window: &mut dyn Window, dpi_factor: f32);
unsafe fn draw_handle(
        &self,
        draw: DrawIface<'_, DS>,
        window: &mut dyn Window
    ) -> StackDst<dyn DrawHandle>;
fn clear_color(&self) -> Rgba; }
This is supported on crate feature stack_dst only.
Expand description

As Theme, but without associated types

This trait is implemented automatically for all implementations of Theme. It is intended only for use where a less parameterised trait is required.

Required methods

Get current config

Apply/set the passed config

Theme initialisation

See also Theme::init.

Construct per-window storage

Uses a StackDst to avoid requiring an associated type.

See also Theme::new_window.

Update a window created by Theme::new_window

See also Theme::update_window.

Construct a DrawHandle object

Uses a StackDst to avoid requiring an associated type.

See also Theme::draw_handle.

Safety

All references passed into the method must outlive the returned object.

Background colour

See also Theme::clear_color.

Implementors