It derives from <GObject>.
Used by list widgets to represent items in a
<GListModel>.
<GtkListItem> objects are managed by the list
widget (with its factory) and cannot be created by applications, but
they need to be populated by application code. This is done by calling
list-item:set-child.
<GtkListItem> objects exist in 2 stages:
list-item:item property is set to NULL.
list-item:item property is not
NULL.
The accessible description to set on the listitem.
Its value is a string, or #f.
Set it with (set! (list-item:accessible-description self) value).
The accessible label to set on the listitem.
Its value is a string, or #f.
Set it with (set! (list-item:accessible-label self) value).
If the item can be activated by the user.
Its value is a boolean.
Set it with (set! (list-item:activatable self) value).
Widget used for display.
Its value is a <GtkWidget>, or #f.
Set it with (set! (list-item:child self) value).
If the item can be focused with the keyboard.
Its value is a boolean.
Set it with (set! (list-item:focusable self) value).
Position of the item.
Its value is an unsigned 32-bit integer.
It is read only.
If the item can be selected by the user.
Its value is a boolean.
Set it with (set! (list-item:selectable self) value).
If the item is currently selected.
Its value is a boolean.
It is read only.
Gets the accessible description of self.
Passed: a <GtkListItem>.
a listitem
Returned: a string.
the accessible description
Gets the accessible label of self.
Passed: a <GtkListItem>.
a listitem
Returned: a string.
the accessible label
Checks if a listitem has been set to be activatable via
list-item:set-activatable.
Passed: a <GtkListItem>.
a listitem
Returned: a boolean.
true if the item is activatable
Gets the child previously set via list-item:set-child or NULL if none was set.
Passed: a <GtkListItem>.
a listitem
Returned: a <GtkWidget>, or #f.
The child
Checks if a listitem has been set to be focusable via
list-item:set-focusable.
Passed: a <GtkListItem>.
a lits item
Returned: a boolean.
true if the item is focusable
Gets the model item that associated with self.
If self is unbound, this function returns NULL.
Passed: a <GtkListItem>.
a listitem
Returned: a <GObject>, or #f.
The item displayed
Gets the position in the model that self currently displays.
If self is unbound, GTK_INVALID_LIST_POSITION is returned.
Passed: a <GtkListItem>.
a listitem
Returned: an unsigned 32-bit integer.
The position of this item
Checks if a listitem has been set to be selectable via
list-item:set-selectable.
Do not confuse this function with list-item:get-selected?.
Passed: a <GtkListItem>.
a listitem
Returned: a boolean.
true if the item is selectable
Checks if the item is displayed as selected.
The selected state is maintained by the list widget and its model and cannot be set otherwise.
Passed: a <GtkListItem>.
a listitem
Returned: a boolean.
true if the item is selected.
Sets the accessible description for the listitem.
The accessible description may be used by e.g. screen readers.
Passed: a <GtkListItem>.
a listitem
Passed: a string.
the description
Sets the accessible label for the listitem.
The accessible label may be used by e.g. screen readers.
Passed: a <GtkListItem>.
a listitem
Passed: a string.
the label
Sets self to be activatable.
If an item is activatable, double-clicking on the item, using the Return
key or calling widget:activate? will
activate the item. Activating instructs the containing view to handle
activation. <GtkListView> for example will be
emitting the list-view:activate
signal.
By default, listitems are activatable.
Passed: a <GtkListItem>.
a listitem
Passed: a boolean.
if the item should be activatable
Sets the child to be used for this listitem.
This function is typically called by applications when setting up a listitem so that the widget can be reused when binding it multiple times.
Passed: a <GtkListItem>.
a listitem
Passed, or left out: a <GtkWidget>, or #f.
The listitem’s child or NULL to unset
Sets self to be focusable.
If an item is focusable, it can be focused using the keyboard. This
works similar to widget:set-focusable.
Note that if items are not focusable, the keyboard cannot be used to activate them and selecting only works if one of the listitem’s children is focusable.
By default, listitems are focusable.
Passed: a <GtkListItem>.
a listitem
Passed: a boolean.
if the item should be focusable
Sets self to be selectable.
If an item is selectable, clicking on the item or using the keyboard will try to select or unselect the item. If this succeeds is up to the model to determine, as it is managing the selected state.
Note that this means that making an item non-selectable has no influence on the selected state at all. A non-selectable item may still be selected.
By default, listitems are selectable. When rebinding them to a new item, they will also be reset to be selectable by GTK.
Passed: a <GtkListItem>.
a listitem
Passed: a boolean.
if the item should be selectable