ColumnViewRow#
Added in version 4.12.
Superclasses: Object
GtkColumnViewRow
is used by ColumnView
to allow configuring
how rows are displayed.
It is not used to set the widgets displayed in the individual cells. For that
see set_factory
and GtkColumnViewCell
.
Methods#
- class ColumnViewRow
-
- get_activatable() bool #
Checks if the row has been set to be activatable via
set_activatable()
.Added in version 4.12.
- get_focusable() bool #
Checks if a row item has been set to be focusable via
set_focusable()
.Added in version 4.12.
- get_item() Object | None #
Gets the model item that associated with
self
.If
self
is unbound, this function returnsNone
.Added in version 4.12.
- get_position() int #
Gets the position in the model that
self
currently displays.If
self
is unbound,INVALID_LIST_POSITION
is returned.Added in version 4.12.
- get_selectable() bool #
Checks if the row has been set to be selectable via
set_selectable()
.Do not confuse this function with
get_selected
.Added in version 4.12.
- get_selected() bool #
Checks if the item is selected that this row corresponds to.
The selected state is maintained by the list widget and its model and cannot be set otherwise.
Added in version 4.12.
- set_accessible_description(description: str) None #
Sets the accessible description for the row, which may be used by e.g. screen readers.
Added in version 4.12.
- Parameters:
description – the description
- set_accessible_label(label: str) None #
Sets the accessible label for the row, which may be used by e.g. screen readers.
Added in version 4.12.
- Parameters:
label – the label
- set_activatable(activatable: bool) None #
Sets
self
to be activatable.If a row is activatable, double-clicking on the row, using the Return key or calling
activate()
will activate the row. Activating instructs the containing columnview to emit theactivate
signal.By default, row are activatable.
Added in version 4.12.
- Parameters:
activatable – if the row should be activatable
- set_focusable(focusable: bool) None #
Sets
self
to be focusable.If a row is focusable, it can be focused using the keyboard. This works similar to
set_focusable
.Note that if row are not focusable, the contents of cells can still be focused if they are focusable.
By default, rows are focusable.
Added in version 4.12.
- Parameters:
focusable – if the row should be focusable
- set_selectable(selectable: bool) None #
Sets
self
to be selectable.If a row is selectable, clicking on the row or using the keyboard will try to select or unselect the row. Whether this succeeds is up to the model to determine, as it is managing the selected state.
Note that this means that making a row non-selectable has no influence on the selected state at all. A non-selectable row may still be selected.
By default, rows are selectable.
Added in version 4.12.
- Parameters:
selectable – if the row should be selectable
Properties#
- class ColumnViewRow