Trait CustomWindow

Source
pub trait CustomWindow: 'static {
    type Param;

    // Required method
    fn invoke(&mut self, pass: PassId, rect: Rect, param: Self::Param);
}
Expand description

Per-window state for a custom draw pipe

One instance is constructed per window. Since the CustomPipe is not accessible during a widget’s kas::Layout::draw calls, this struct must batch per-frame draw data.

Required Associated Types§

Source

type Param

User parameter type

Required Methods§

Source

fn invoke(&mut self, pass: PassId, rect: Rect, param: Self::Param)

Invoke user-defined custom routine

Custom add-primitives / update function called from user code by DrawCustom::custom.

Implementations on Foreign Types§

Source§

impl CustomWindow for ()

A dummy implementation (does nothing)

Source§

type Param = Void

Source§

fn invoke(&mut self, _: PassId, _: Rect, _: Self::Param)

Implementors§