Adw.PreferencesGroup¶
- 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 |
|||
r/w/en |
|||
r/w/en |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent_instance |
r |
Class Details¶
- class Adw.PreferencesGroup(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
A group of preference rows.
<picture> <source srcset=”preferences-group-dark.png” media=”(prefers-color-scheme: dark)”> <img src=”preferences-group.png” alt=”preferences-group”> </picture>
An
AdwPreferencesGroup
represents a group or tightly related preferences, which in turn are represented by [class`PreferencesRow`].To summarize the role of the preferences it gathers, a group can have both a title and a description. The title will be used by [class`PreferencesDialog`] to let the user look for a preference.
The
AdwPreferencesGroup
implementation of the [iface`Gtk`.Buildable] interface supports adding [class`PreferencesRow`]s to the list by omitting “type”. If “type” is omitted and the widget isn’t a [class`PreferencesRow`] the child is added to a box below the list.When the “type” attribute of a child is
header-suffix
, the child is set as the suffix on the end of the title and description.- CSS nodes
AdwPreferencesGroup
has a single CSS node with namepreferencesgroup
.- Accessibility
AdwPreferencesGroup
uses theGTK_ACCESSIBLE_ROLE_GROUP
role.- classmethod new()¶
- Returns:
the newly created
AdwPreferencesGroup
- Return type:
Creates a new
AdwPreferencesGroup
.
- add(child)¶
- Parameters:
child (
Gtk.Widget
) – the widget to add
Adds a child to self.
- get_description()¶
-
Gets the description of self.
- get_header_suffix()¶
- Returns:
the suffix for self's header.
- Return type:
Gtk.Widget
orNone
Gets the suffix for self's header.
New in version 1.1.
- remove(child)¶
- Parameters:
child (
Gtk.Widget
) – the child to remove
Removes a child from self.
- set_description(description)¶
-
Sets the description for self.
- set_header_suffix(suffix)¶
- Parameters:
suffix (
Gtk.Widget
orNone
) – the suffix to set
Sets the suffix for self's header.
Displayed above the list, next to the title and description.
Suffixes are commonly used to show a button or a spinner for the whole group.
New in version 1.1.
Property Details¶
- Adw.PreferencesGroup.props.description¶
- Name:
description
- Type:
- Default Value:
''
- Flags:
The description for this group of preferences.
- Adw.PreferencesGroup.props.header_suffix¶
- Name:
header-suffix
- Type:
- Default Value:
- Flags:
The header suffix widget.
Displayed above the list, next to the title and description.
Suffixes are commonly used to show a button or a spinner for the whole group.
New in version 1.1.
- Adw.PreferencesGroup.props.title¶
- Name:
title
- Type:
- Default Value:
''
- Flags:
The title for this group of preferences.