FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    HierarchicalExpanderColumn

    struct · ferroui-controls-treedatagrid · v0.5.0

    struct HierarchicalExpanderColumn<M: TreeModel>
    

    HierarchicalExpanderColumn<TModel>.

    View source

    Members

    new

    fn new(inner: Rc<dyn IViewColumn<M>>, child_selector: impl Fn(&Rc<M>) -> Option<Models<M>> + 'static, has_children_selector: Option<Accessor<M, bool>>, is_expanded_selector: Option<Accessor<M, bool>>) -> Rc<Self>
    

    A column that shows inner with an expander. child_selector gives the children of a model; has_children_selector whether a model has children without selecting them (only needed when selecting the children is expensive); is_expanded_selector a read/write expansion state of the model (its setter writes the state back).

    Source

    inner

    fn inner(self: &Self) -> &Rc<dyn IViewColumn<M>>
    

    The column that defines how the cells are shown.

    Source

    child_selector

    fn child_selector(self: &Self) -> &ChildSelector<M>
    

    The selector of the child models.

    Source

    has_children_selector

    fn has_children_selector(self: &Self) -> Option<&Accessor<M, bool>>
    

    Source

    is_expanded_selector

    fn is_expanded_selector(self: &Self) -> Option<&Accessor<M, bool>>
    

    Source

    actual_width

    fn actual_width(self: &Self) -> f64
    

    The width of the column after measurement.

    Source

    has_children

    fn has_children(self: &Self, model: &Rc<M>) -> bool
    

    Whether model has children.

    Source

    get_child_models

    fn get_child_models(self: &Self, model: &Rc<M>) -> Option<Models<M>>
    

    The child models of model.

    Source

    create_expander_cell

    fn create_expander_cell(self: &Self, row: Rc<dyn IExpanderRow<M>>, row_ref: &RowRef) -> CellRef
    

    The cell of the expander row row.

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.