Trait embedded_layout::layout::linear::Orientation [−][src]
pub trait Orientation: Copy + Clone { type Secondary: SecondaryAlignment + Alignment; fn destructure_size(size: Size) -> (u32, u32); fn create_size(primary: u32, secondary: u32) -> Size; fn place(
&self,
view: &mut dyn View,
size: Size,
previous: Rectangle,
n: usize,
count: usize
); }
Expand description
Helper trait that describes a linear layout orientation.
Associated Types
Secondary alignment that will be applied to all the views
Required methods
Destructure Size into (primary_size, secondary_size)
fn create_size(primary: u32, secondary: u32) -> Size
fn create_size(primary: u32, secondary: u32) -> SizeCreate a Size from primary and secondary size values
Implementors
impl<Secondary, Spacing> Orientation for Horizontal<Secondary, Spacing> where
Secondary: SecondaryAlignment + VerticalAlignment,
Spacing: ElementSpacing, impl<Secondary, Spacing> Orientation for Vertical<Secondary, Spacing> where
Secondary: SecondaryAlignment + HorizontalAlignment,
Spacing: ElementSpacing,