ListBoxRow#
Superclasses: Widget
, InitiallyUnowned
, Object
Implemented Interfaces: Accessible
, Actionable
, Buildable
, ConstraintTarget
GtkListBoxRow
is the kind of widget that can be added to a GtkListBox
.
Constructors#
Methods#
- class ListBoxRow
- changed() None #
Marks
row
as changed, causing any state that depends on this to be updated.This affects sorting, filtering and headers.
Note that calls to this method must be in sync with the data used for the row functions. For instance, if the list is mirroring some external data set, and two rows changed in the external data set then when you call
changed()
on the first row the sort function must only read the new data for the first of the two changed rows, otherwise the resorting of the rows will be wrong.This generally means that if you don’t fully control the data model you have to duplicate the data that affects the listbox row functions into the row widgets themselves. Another alternative is to call
invalidate_sort
on any model change, but that is more expensive.
- get_header() Widget | None #
Returns the current header of the
row
.This can be used in a
Gtk.ListBoxUpdateHeaderFunc
to see if there is a header set already, and if so to update the state of it.
- set_activatable(activatable: bool) None #
Set whether the row is activatable.
- Parameters:
activatable –
True
to mark the row as activatable
- set_child(child: Widget | None = None) None #
Sets the child widget of
self
.- Parameters:
child – the child widget
Properties#
Signals#
- class ListBoxRow.signals
- activate() None #
This is a keybinding signal, which will cause this row to be activated.
If you want to be notified when the user activates a row (by key or not), use the
row_activated
signal on the row’s parentGtkListBox
.
Virtual Methods#
Fields#
- class ListBoxRow
- parent_instance#