Skip to main content

Arrangement

Trait Arrangement 

Source
pub trait Arrangement {
    // Required method
    fn arrange(&self, total_size: f32, sizes: &[f32], out_positions: &mut [f32]);
}
Expand description

Trait implemented by arrangement strategies that distribute children on an axis.

Required Methods§

Source

fn arrange(&self, total_size: f32, sizes: &[f32], out_positions: &mut [f32])

Computes the position for each child given the available space and their sizes.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§