Skip to main content

StyleMisc

Trait StyleMisc 

Source
pub trait StyleMisc {
    // Provided methods
    fn swatch_size(&self, _ui: &mut Ui, _sp: &mut Sp<'_>) -> (i32, i32) { ... }
    fn swatch(&self, _ui: &mut Ui, _sp: &Sp<'_>) { ... }
    fn color_preview(&self, _ui: &mut Ui, _argb: u32, _r: [i32; 4]) { ... }
    fn color_marker(&self, _ui: &mut Ui, _x_fx: i32, _y_fx: i32) { ... }
    fn color_wheel(&self, _ui: &mut Ui, _sp: &Sp<'_>) { ... }
    fn box_deco(&self, _ui: &mut Ui, _sp: &Sp<'_>) { ... }
    fn window_bg(&self, _ui: &mut Ui, _w: i32, _h: i32) { ... }
}
Expand description

swatches, colour picker parts, box decorations, window background (misc.s)

Provided Methods§

Source

fn swatch_size(&self, _ui: &mut Ui, _sp: &mut Sp<'_>) -> (i32, i32)

value colour, value2 1 = selected, ev

Source

fn swatch(&self, _ui: &mut Ui, _sp: &Sp<'_>)

Source

fn color_preview(&self, _ui: &mut Ui, _argb: u32, _r: [i32; 4])

Source

fn color_marker(&self, _ui: &mut Ui, _x_fx: i32, _y_fx: i32)

marker at 24.8 px

Source

fn color_wheel(&self, _ui: &mut Ui, _sp: &Sp<'_>)

rect = the wheel’s square, s[0] radius px, value hue (tenths of a degree), value2 saturation 0..1000, s[1] 1 = focus visual

Source

fn box_deco(&self, _ui: &mut Ui, _sp: &Sp<'_>)

BOX_BG / BOX_CARD / BOX_LAYER decoration (sp: rectangle, flags)

Source

fn window_bg(&self, _ui: &mut Ui, _w: i32, _h: i32)

the background of a window’s whole surface (px)

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§