Implement Stack widget
It can be used to stack elements on top of each other!
This commit is contained in:
parent
5ef593ce53
commit
0c74d26456
4 changed files with 357 additions and 2 deletions
|
|
@ -54,7 +54,7 @@ impl<'a> Layout<'a> {
|
|||
}
|
||||
|
||||
/// Returns an iterator over the [`Layout`] of the children of a [`Node`].
|
||||
pub fn children(self) -> impl Iterator<Item = Layout<'a>> {
|
||||
pub fn children(self) -> impl DoubleEndedIterator<Item = Layout<'a>> {
|
||||
self.node.children().iter().map(move |node| {
|
||||
Layout::with_offset(
|
||||
Vector::new(self.position.x, self.position.y),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue