Adw.StatusPage

g Adw.StatusPage Adw.StatusPage GObject.GInterface GObject.GInterface Gtk.Accessible Gtk.Accessible GObject.GInterface->Gtk.Accessible Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable Gtk.ConstraintTarget Gtk.ConstraintTarget GObject.GInterface->Gtk.ConstraintTarget GObject.InitiallyUnowned GObject.InitiallyUnowned Gtk.Widget Gtk.Widget GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.Accessible->Gtk.Widget Gtk.Buildable->Gtk.Widget Gtk.ConstraintTarget->Gtk.Widget Gtk.Widget->Adw.StatusPage

Subclasses:

None

Methods

Inherited:

Gtk.Widget (181), GObject.Object (37), Gtk.Accessible (15), Gtk.Buildable (1)

Structs:

Gtk.WidgetClass (18), GObject.ObjectClass (5)

class

new ()

get_child ()

get_description ()

get_icon_name ()

get_paintable ()

get_title ()

set_child (child)

set_description (description)

set_icon_name (icon_name)

set_paintable (paintable)

set_title (title)

Virtual Methods

Inherited:

Gtk.Widget (25), GObject.Object (7), Gtk.Accessible (6), Gtk.Buildable (9)

Properties

Inherited:

Gtk.Widget (34), Gtk.Accessible (1)

Name

Type

Flags

Short Description

child

Gtk.Widget

r/w/en

description

str

r/w/en

icon-name

str

r/w/en

paintable

Gdk.Paintable

r/w/en

title

str

r/w/en

Signals

Inherited:

Gtk.Widget (13), GObject.Object (1)

Fields

Inherited:

Gtk.Widget (13), GObject.Object (1)

Class Details

class Adw.StatusPage(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

Adw.StatusPageClass

A page used for empty/error states and similar use-cases.

<picture> <source srcset=”status-page-dark.png” media=”(prefers-color-scheme: dark)”> <img src=”status-page.png” alt=”status-page”> </picture>

The AdwStatusPage widget can have an icon, a title, a description and a custom widget which is displayed below them.

CSS nodes

AdwStatusPage has a main CSS node with name statuspage.

AdwStatusPage can use the .compact style class for when it needs to fit into a small space such a sidebar or a popover.

classmethod new()
Returns:

the newly created AdwStatusPage

Return type:

Gtk.Widget

Creates a new AdwStatusPage.

get_child()
Returns:

the child widget of self

Return type:

Gtk.Widget or None

Gets the child widget of self.

get_description()
Returns:

the description

Return type:

str or None

Gets the description markup for self.

get_icon_name()
Returns:

the icon name

Return type:

str or None

Gets the icon name for self.

get_paintable()
Returns:

the paintable

Return type:

Gdk.Paintable or None

Gets the paintable for self.

get_title()
Returns:

the title

Return type:

str

Gets the title for self.

set_child(child)
Parameters:

child (Gtk.Widget or None) – the child widget

Sets the child widget of self.

set_description(description)
Parameters:

description (str or None) – the description

Sets the description markup for self.

The description is displayed below the title. It is parsed as Pango markup.

set_icon_name(icon_name)
Parameters:

icon_name (str or None) – the icon name

Sets the icon name for self.

Changing this will set [property`StatusPage`:py:data::paintable<Adw.StatusPage.props.paintable>] to NULL.

set_paintable(paintable)
Parameters:

paintable (Gdk.Paintable or None) – the paintable

Sets the paintable for self.

Changing this will set [property`StatusPage`:py:data::icon-name<Adw.StatusPage.props.icon_name>] to NULL.

set_title(title)
Parameters:

title (str) – the title

Sets the title for self.

The title is displayed below the icon. It is not parsed as Pango markup.

Property Details

Adw.StatusPage.props.child
Name:

child

Type:

Gtk.Widget

Default Value:

None

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

The child widget.

Adw.StatusPage.props.description
Name:

description

Type:

str

Default Value:

''

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

The description markup to be displayed below the title.

Adw.StatusPage.props.icon_name
Name:

icon-name

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

The name of the icon to be used.

Changing this will set [property`StatusPage`:py:data::paintable<Adw.StatusPage.props.paintable>] to NULL.

Adw.StatusPage.props.paintable
Name:

paintable

Type:

Gdk.Paintable

Default Value:

None

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

The paintable to be used.

Changing this will set [property`StatusPage`:py:data::icon-name<Adw.StatusPage.props.icon_name>] to NULL.

Adw.StatusPage.props.title
Name:

title

Type:

str

Default Value:

''

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

The title to be displayed below the icon.

It is not parsed as Pango markup.