pub trait Draw {
// Required method
fn draw(&self, g: &mut Gfx<'_>, r: [i32; 4]);
}Expand description
a custom draw function (cmd_custom: canvases, custom tracks): draw(g, rect) at render time with the clip set to rect (absolute px). Its identity (the Rc) and the version of the command decide whether it is redrawn.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".