Trait freya::prelude::LayoutMeasurer

source ·
pub trait LayoutMeasurer<Key>
where Key: NodeKey,
{ // Required methods fn measure( &mut self, node_id: Key, node: &Node, size: &Size2D<f32, Measure> ) -> Option<(Size2D<f32, Measure>, Arc<Map<dyn Any + Sync + Send>>)>; fn should_measure_inner_children(&mut self, node_id: Key) -> bool; // Provided method fn notify_layout_references(&self, _node_id: Key, _layout_node: &LayoutNode) { ... } }

Required Methods§

source

fn measure( &mut self, node_id: Key, node: &Node, size: &Size2D<f32, Measure> ) -> Option<(Size2D<f32, Measure>, Arc<Map<dyn Any + Sync + Send>>)>

source

fn should_measure_inner_children(&mut self, node_id: Key) -> bool

Provided Methods§

source

fn notify_layout_references(&self, _node_id: Key, _layout_node: &LayoutNode)

Implementations on Foreign Types§

source§

impl<'a> LayoutMeasurer<EntityId> for SkiaMeasurer<'a>

source§

fn measure( &mut self, node_id: EntityId, _node: &Node, area_size: &Size2D<f32, Measure> ) -> Option<(Size2D<f32, Measure>, Arc<Map<dyn Any + Sync + Send>>)>

source§

fn should_measure_inner_children(&mut self, node_id: EntityId) -> bool

source§

fn notify_layout_references(&self, node_id: EntityId, layout_node: &LayoutNode)

Implementors§