gtk.tree_list_row

Module for [TreeListRow] class

Types 3

[gtk.tree_list_row.TreeListRow] is used by [gtk.tree_list_model.TreeListModel] to represent items.

It allows navigating the model as a tree and modify the state of rows.

[gtk.tree_list_row.TreeListRow] instances are created by a [gtk.tree_list_model.TreeListModel] only when the [gtk.tree_list_model.TreeListModel.passthrough] property is not set.

There are various support objects that can make use of [gtk.tree_list_row.TreeListRow] objects, such as the [gtk.tree_expander.TreeExpander] widget that allows displaying an icon to expand or collapse a row or [gtk.tree_list_row_sorter.TreeListRowSorter] that makes it possible to sort trees properly.

Methods
GType _gType() @property
TreeListRow self()Returns `this`, for use in `with` statements.
TreeListRowGidBuilder builder()Get builder for [gtk.treelistrow.TreeListRow] Returns: New builder object
gio.list_model.ListModel children() @propertyGet `children` property. Returns: The model holding the row's children.
uint depth() @propertyGet `depth` property. Returns: The depth in the tree of this row.
bool expandable() @propertyGet `expandable` property. Returns: If this row can ever be expanded.
bool expanded() @propertyGet `expanded` property. Returns: If this row is currently expanded.
void expanded(bool propval) @propertySet `expanded` property. Params: propval = If this row is currently expanded.
gobject.object.ObjectWrap item() @propertyGet `item` property. Returns: The item held in this row.
gtk.tree_list_row.TreeListRow getChildRow(uint position)If self is not expanded or position is greater than the number of children, null is returned.
gio.list_model.ListModel getChildren()If the row is expanded, gets the model holding the children of self.
uint getDepth()Gets the depth of this row.
bool getExpanded()Gets if a row is currently expanded. Returns: true if the row is expanded
gobject.object.ObjectWrap getItem()Gets the item corresponding to this row, Returns: The item of this row. This function is only marked as nullable for backwards compatibility reasons.
gtk.tree_list_row.TreeListRow getParent()Gets the row representing the parent for self.
uint getPosition()Returns the position in the [gtk.treelistmodel.TreeListModel] that self occupies at the moment. Returns: The position in the model
bool isExpandable()Checks if a row can be expanded.
void setExpanded(bool expanded)Expands or collapses a row.
Constructors
this(void * ptr, Flag!"Take" take)
Methods
T expanded(bool propval)Set `expanded` property. Params: propval = If this row is currently expanded. Returns: Builder instance for fluent chaining

Fluent builder for [gtk.tree_list_row.TreeListRow]