Skip to main content

TreeColumns

Trait TreeColumns 

Source
pub trait TreeColumns<T: TreeModel> {
    // Required methods
    fn column_count(&self) -> usize;
    fn tree_column_index(&self) -> usize;
    fn minimum_width(&self) -> u16;
    fn ideal_width(&self) -> u16;
    fn widths(&self, available: u16) -> SmallVec<[u16; 8]>;
    fn header(&self) -> Option<Row<'_>>;
    fn cells<'a>(
        &'a self,
        model: &'a T,
        id: T::Id,
        context: &TreeRowContext<'_>,
        tree_cell: Cell<'a>,
    ) -> SmallVec<[Cell<'a>; 8]>;

    // Provided method
    fn header_height(&self) -> u16 { ... }
}
Expand description

Lays out columns and builds every cell in a row.

Required Methods§

Source

fn column_count(&self) -> usize

Source

fn tree_column_index(&self) -> usize

Source

fn minimum_width(&self) -> u16

Source

fn ideal_width(&self) -> u16

Source

fn widths(&self, available: u16) -> SmallVec<[u16; 8]>

Source

fn header(&self) -> Option<Row<'_>>

Source

fn cells<'a>( &'a self, model: &'a T, id: T::Id, context: &TreeRowContext<'_>, tree_cell: Cell<'a>, ) -> SmallVec<[Cell<'a>; 8]>

Provided Methods§

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§