Trait unsegen::container::Layout [−][src]
pub trait Layout<C: ContainerProvider>: Debug { fn space_demand(&self, containers: &C) -> Demand2D; fn layout(
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>; }
Expand description
A Layouter managing screen real estate for multiple containers
Required methods
fn space_demand(&self, containers: &C) -> Demand2D
[src]
fn space_demand(&self, containers: &C) -> Demand2D
[src]Calculate the space demand required for all of the provided containers
fn layout(
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
[src]
fn layout(
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
[src]Specify how the provided containers should be layed out in the provided area, and how they should be separated by lines.
Note that the implementor is strictly required to enforce that returned windows and lines DO NOT INTERSECT!
Implementors
impl<'a, C: ContainerProvider> Layout<C> for HSplit<'a, C>
[src]
impl<'a, C: ContainerProvider> Layout<C> for HSplit<'a, C>
[src]fn space_demand(&self, containers: &C) -> Demand2D
[src]
fn layout(
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
[src]
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
impl<'a, C: ContainerProvider> Layout<C> for VSplit<'a, C>
[src]
impl<'a, C: ContainerProvider> Layout<C> for VSplit<'a, C>
[src]fn space_demand(&self, containers: &C) -> Demand2D
[src]
fn layout(
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
[src]
&self,
available_area: Rectangle,
containers: &C
) -> LayoutOutput<C::Index>
impl<C: ContainerProvider> Layout<C> for Leaf<C>
[src]
impl<C: ContainerProvider> Layout<C> for Leaf<C>
[src]