Gtk.FlowBoxChild¶
- Subclasses:
None
Methods¶
- Inherited:
Gtk.Widget (181), GObject.Object (37), Gtk.Accessible (15), Gtk.Buildable (1)
- Structs:
class |
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Gtk.Widget (25), GObject.Object (7), Gtk.Accessible (6), Gtk.Buildable (9)
|
Properties¶
- Inherited:
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r/w/en |
Signals¶
- Inherited:
Name |
Short Description |
---|---|
Emitted when the user activates a child widget in a |
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent_instance |
r |
Class Details¶
- class Gtk.FlowBoxChild(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
GtkFlowBoxChild
is the kind of widget that can be added to aGtkFlowBox
.- classmethod new()[source]¶
- Returns:
a new
GtkFlowBoxChild
- Return type:
Creates a new
GtkFlowBoxChild
.This should only be used as a child of a
GtkFlowBox
.
- changed()[source]¶
Marks self as changed, causing any state that depends on this to be updated.
This affects sorting and filtering.
Note that calls to this method must be in sync with the data used for the sorting and filtering functions. For instance, if the list is mirroring some external data set, and *two* children changed in the external data set when you call
Gtk.FlowBoxChild.changed
() on the first child, the sort function must only read the new data for the first of the two changed children, otherwise the resorting of the children 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 sorting and filtering functions into the widgets themselves.
Another alternative is to call [method`Gtk`.FlowBox.invalidate_sort] on any model change, but that is more expensive.
- get_child()[source]¶
- Returns:
the child widget of self
- Return type:
Gtk.Widget
orNone
Gets the child widget of self.
- get_index()[source]¶
- Returns:
the index of the self, or -1 if the self is not in a flow box
- Return type:
Gets the current index of the self in its
GtkFlowBox
container.
- set_child(child)[source]¶
- Parameters:
child (
Gtk.Widget
orNone
) – the child widget
Sets the child widget of self.
- do_activate() virtual¶
Signal Details¶
- Gtk.FlowBoxChild.signals.activate(flow_box_child)¶
- Signal Name:
activate
- Flags:
- Parameters:
flow_box_child (
Gtk.FlowBoxChild
) – The object which received the signal
Emitted when the user activates a child widget in a
GtkFlowBox
.This can happen either by clicking or double-clicking, or via a keybinding.
This is a keybinding signal, but it can be used by applications for their own purposes.
The default bindings are <kbd>Space</kbd> and <kbd>Enter</kbd>.
Property Details¶
- Gtk.FlowBoxChild.props.child¶
- Name:
child
- Type:
- Default Value:
- Flags:
The child widget.