ViewStackPage#

class ViewStackPage(**properties: Any)#

Superclasses: Object

Implemented Interfaces: Accessible

An auxiliary class used by ViewStack.

Methods#

class ViewStackPage
get_badge_number() int#

Gets the badge number for this page.

get_child() Widget#

Gets the stack child to which self belongs.

get_icon_name() str | None#

Gets the icon name of the page.

get_name() str | None#

Gets the name of the page.

get_needs_attention() bool#

Gets whether the page requires the user attention.

get_title() str | None#

Gets the page title.

get_use_underline() bool#

Gets whether underlines in the page title indicate mnemonics.

get_visible() bool#

Gets whether self is visible in its AdwViewStack.

This is independent from the visible property of its widget.

set_badge_number(badge_number: int) None#

Sets the badge number for this page.

ViewSwitcher can display it as a badge next to the page icon. It is commonly used to display a number of unread items within the page.

It can be used together with needs_attention.

Parameters:

badge_number – the new value to set

set_icon_name(icon_name: str | None = None) None#

Sets the icon name of the page.

Parameters:

icon_name – the icon name

set_name(name: str | None = None) None#

Sets the name of the page.

Parameters:

name – the page name

set_needs_attention(needs_attention: bool) None#

Sets whether the page requires the user attention.

ViewSwitcher will display it as a dot next to the page icon.

Parameters:

needs_attention – the new value to set

set_title(title: str | None = None) None#

Sets the page title.

Parameters:

title – the page title

set_use_underline(use_underline: bool) None#

Sets whether underlines in the page title indicate mnemonics.

Parameters:

use_underline – the new value to set

set_visible(visible: bool) None#

Sets whether page is visible in its AdwViewStack.

This is independent from the visible property of child.

Parameters:

visible – whether self is visible

Properties#

class ViewStackPage
props.badge_number: int#

The type of the None singleton.

props.child: Widget#

The type of the None singleton.

props.icon_name: str#

The type of the None singleton.

props.name: str#

The type of the None singleton.

props.needs_attention: bool#

The type of the None singleton.

props.title: str#

The type of the None singleton.

props.use_underline: bool#

The type of the None singleton.

props.visible: bool#

The type of the None singleton.