pub trait ChildrenExt: Sized {
// Required method
fn get_children(&mut self) -> &mut Vec<Element>;
// Provided methods
fn children(self, children: impl IntoIterator<Item = Element>) -> Self { ... }
fn maybe_child<C>(self, child: Option<C>) -> Self
where C: IntoElement { ... }
fn child<C>(self, child: C) -> Self
where C: IntoElement { ... }
}Expand description
Trait for composing child elements.
Required Methods§
Provided Methods§
Sourcefn children(self, children: impl IntoIterator<Item = Element>) -> Self
fn children(self, children: impl IntoIterator<Item = Element>) -> Self
Sourcefn maybe_child<C>(self, child: Option<C>) -> Selfwhere
C: IntoElement,
fn maybe_child<C>(self, child: Option<C>) -> Selfwhere
C: IntoElement,
Sourcefn child<C>(self, child: C) -> Selfwhere
C: IntoElement,
fn child<C>(self, child: C) -> Selfwhere
C: IntoElement,
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
§impl ChildrenExt for Accordion
impl ChildrenExt for Accordion
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Attached
impl ChildrenExt for Attached
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Button
impl ChildrenExt for Button
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for ButtonSegment
impl ChildrenExt for ButtonSegment
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Canvas
impl ChildrenExt for Canvas
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Card
impl ChildrenExt for Card
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Chip
impl ChildrenExt for Chip
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for CursorArea
impl ChildrenExt for CursorArea
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Draggable
impl ChildrenExt for Draggable
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for DraggableCanvas
impl ChildrenExt for DraggableCanvas
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for FloatingTab
impl ChildrenExt for FloatingTab
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for ImageViewer
impl ChildrenExt for ImageViewer
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Link
impl ChildrenExt for Link
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Menu
impl ChildrenExt for Menu
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for MenuButton
impl ChildrenExt for MenuButton
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for MenuContainer
impl ChildrenExt for MenuContainer
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for MenuItem
impl ChildrenExt for MenuItem
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for OverflowedContent
impl ChildrenExt for OverflowedContent
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Popup
impl ChildrenExt for Popup
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for PopupButtons
impl ChildrenExt for PopupButtons
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for PopupContent
impl ChildrenExt for PopupContent
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for ResizableDraggable
impl ChildrenExt for ResizableDraggable
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for ResizablePanel
impl ChildrenExt for ResizablePanel
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for ScrollView
impl ChildrenExt for ScrollView
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for SegmentedButton
impl ChildrenExt for SegmentedButton
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Select
impl ChildrenExt for Select
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for SideBarItem
impl ChildrenExt for SideBarItem
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Skeleton
impl ChildrenExt for Skeleton
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for SubMenu
impl ChildrenExt for SubMenu
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Table
impl ChildrenExt for Table
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for TableBody
impl ChildrenExt for TableBody
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for TableCell
impl ChildrenExt for TableCell
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for TableHead
impl ChildrenExt for TableHead
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for TableRow
impl ChildrenExt for TableRow
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for Tile
impl ChildrenExt for Tile
fn get_children(&mut self) -> &mut Vec<Element>
§impl ChildrenExt for TooltipContainer
impl ChildrenExt for TooltipContainer
fn get_children(&mut self) -> &mut Vec<Element>
§impl<T> ChildrenExt for Portal<T>
impl<T> ChildrenExt for Portal<T>
fn get_children(&mut self) -> &mut Vec<Element>
Implementors§
impl ChildrenExt for Image
impl ChildrenExt for Paragraph
Children added to a Paragraph flow inline at the point they were added, each laid out at
its own measured size, so give them an explicit width and height.