pub trait ContentCx<'a> {
type Spec: Spec;
// Required methods
fn with_paint<R>(
&mut self,
f: impl FnOnce(&mut dyn RenderContext, &mut Widgets<'a>, &VisualView<Self::Spec>, &Tokens) -> R,
) -> R;
fn time_ms(&self) -> u64;
// Provided method
fn ime_area(&mut self, _rect: Rect) { ... }
}Expand description
Required Associated Types§
Required Methods§
Sourcefn with_paint<R>(
&mut self,
f: impl FnOnce(&mut dyn RenderContext, &mut Widgets<'a>, &VisualView<Self::Spec>, &Tokens) -> R,
) -> R
fn with_paint<R>( &mut self, f: impl FnOnce(&mut dyn RenderContext, &mut Widgets<'a>, &VisualView<Self::Spec>, &Tokens) -> R, ) -> R
Run f against this frame’s paint target and registration face.
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".