PropertiesView
struct · ferroui-diagnostics · v0.5.0
struct PropertiesView
The properties of an object for the property grid: the counterpart of the
DataGridCollectionView of the managed original, with its group description (by
Group), its sort description (PropertyComparer) and its filter, presented as a
hierarchical TreeDataGrid source whose root rows are the groups.
Deviation (DEVIATIONS.md, Developer tools): the property grid is a TreeDataGrid, not a DataGrid.
Members
newset_property_type_columnssourcesource_refgroupsitemsset_selection_changedrefreshindex_path_ofrow_index_ofselectedselect
new
fn new(properties: Vec<PropertyViewModelRef>, filter: Rc<dyn Fn(&PropertyViewModelRef) -> bool>) -> Rc<Self>
set_property_type_columns
fn set_property_type_columns(self: &Self, show_property_type: bool)
Shows the type of a property and of its value in one column, or (with show_property_type)
in two.
source
fn source(self: &Self) -> Rc<HierarchicalTreeDataGridSource<PropertiesViewItem>>
The source of the grid.
source_ref
fn source_ref(self: &Self) -> TreeDataGridSourceRef
The source of the grid, as the grid takes it.
groups
fn groups(self: &Self) -> Rc<Vec<Rc<PropertiesViewItem>>>
The rows of the groups.
items
fn items(self: &Self) -> Vec<PropertyViewModelRef>
The properties the view shows, in the order it shows them (foreach (object o in PropertiesView)).
set_selection_changed
fn set_selection_changed(self: &Self, handler: Rc<dyn Fn(Option<PropertyViewModelRef>) -> ()>)
Sets the handler of a change of the selected row (the selected property, None for a
group or no row).
refresh
fn refresh(self: &Self)
Groups, sorts and filters the properties again (Refresh()), keeping the selected
property selected while it is shown.
index_path_of
fn index_path_of(self: &Self, property: &PropertyViewModelRef) -> Option<IndexPath>
The index path of the row of a property.
row_index_of
fn row_index_of(self: &Self, property: &PropertyViewModelRef) -> i32
The index of the row of a property among the rows the grid shows; -1 when it shows
none.
selected
fn selected(self: &Self) -> Option<PropertyViewModelRef>
The selected property; None when no row or a group is selected.
select
fn select(self: &Self, property: Option<&PropertyViewModelRef>)
Selects the row of a property, or clears the selection.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>AnyAnyValueClassDefaultsErasedDestructorIntoEitherTreeModelPartialEqMarkupTyped
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.