pub struct Layout { /* private fields */ }Expand description
The bounds of a widget and its children, using absolute coordinates.
Implementations§
Source§impl Layout
impl Layout
Sourcepub fn move_to(self, position: impl Into<Point>) -> Self
pub fn move_to(self, position: impl Into<Point>) -> Self
Moves the Layout to the given position.
Sourcepub fn parent(&self) -> Option<Rectangle>
pub fn parent(&self) -> Option<Rectangle>
Returns the bounds of the parent of this Layout, if any.
Sourcepub fn iter(
self,
children: &[Tree],
) -> impl DoubleEndedIterator<Item = (Self, &Tree)> + ExactSizeIterator
pub fn iter( self, children: &[Tree], ) -> impl DoubleEndedIterator<Item = (Self, &Tree)> + ExactSizeIterator
Returns an iterator over the children of this Layout.
Sourcepub fn iter_mut(
self,
children: &mut [Tree],
) -> impl DoubleEndedIterator<Item = (Self, &mut Tree)> + ExactSizeIterator
pub fn iter_mut( self, children: &mut [Tree], ) -> impl DoubleEndedIterator<Item = (Self, &mut Tree)> + ExactSizeIterator
Returns a mutable iterator over the children of this Layout.
Trait Implementations§
impl Copy for Layout
impl StructuralPartialEq for Layout
Auto Trait Implementations§
impl Freeze for Layout
impl RefUnwindSafe for Layout
impl Send for Layout
impl Sync for Layout
impl Unpin for Layout
impl UnsafeUnpin for Layout
impl UnwindSafe for Layout
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more