Wnck.Application

g GObject.Object GObject.Object Wnck.Application Wnck.Application GObject.Object->Wnck.Application

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

get (xwindow)

get_icon ()

get_icon_is_fallback ()

get_icon_name ()

get_mini_icon ()

get_n_windows ()

get_name ()

get_pid ()

get_startup_id ()

get_windows ()

get_xid ()

Virtual Methods

Inherited:

GObject.Object (7)

do_icon_changed ()

do_name_changed ()

Properties

None

Signals

Inherited:

GObject.Object (1)

Name

Short Description

icon-changed

Emitted when the icon of app changes.

name-changed

Emitted when the name of app changes.

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent_instance

GObject.Object

r

Class Details

class Wnck.Application(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

Wnck.ApplicationClass

The Wnck.Application struct contains only private fields and should not be directly accessed.

classmethod get(xwindow)
Parameters:

xwindow (int) – the X window ID of a group leader.

Returns:

the Wnck.Application corresponding to xwindow, or None if there no such Wnck.Application could be found. The returned Wnck.Application is owned by libwnck and must not be referenced or unreferenced.

Return type:

Wnck.Application

Gets the Wnck.Application corresponding to the group leader with xwindow as X window ID.

get_icon()
Returns:

the icon for self. The caller should reference the returned GdkPixbuf.Pixbuf if it needs to keep the icon around.

Return type:

GdkPixbuf.Pixbuf

Gets the icon to be used for self. If no icon is set for self, a suboptimal heuristic is used to find an appropriate icon. If no icon was found, a fallback icon is used.

get_icon_is_fallback()
Returns:

True if the icon for self is a fallback, False otherwise.

Return type:

bool

Gets whether a default fallback icon is used for self (because none was set on self).

get_icon_name()
Returns:

the icon name of self, or a fallback icon name if no icon name is available.

Return type:

str

Gets the icon name of self (to be used when self is minimized). Since there is no way to properly find this name, various suboptimal heuristics are used to find it.

get_mini_icon()
Returns:

the mini-icon for self. The caller should reference the returned GdkPixbuf.Pixbuf if it needs to keep the mini-icon around.

Return type:

GdkPixbuf.Pixbuf

Gets the mini-icon to be used for self. If no mini-icon is set for self, a suboptimal heuristic is used to find an appropriate icon. If no mini-icon was found, a fallback mini-icon is used.

get_n_windows()
Returns:

the number of Wnck.Window belonging to self.

Return type:

int

Gets the number of Wnck.Window belonging to self.

get_name()
Returns:

the name of self, or a fallback name if no name is available.

Return type:

str

Gets the name of self. Since there is no way to properly find this name, various suboptimal heuristics are used to find it. GTK+ should probably have a function to allow applications to set the _NET_WM_NAME property on the group leader as the application name, and the EWMH should say that this is where the application name goes.

get_pid()
Returns:

the process ID of self, or 0 if none is available.

Return type:

int

Gets the process ID of self.

get_startup_id()
Returns:

the startup sequence ID used for startup notification of self, or None if none is available.

Return type:

str

Gets the startup sequence ID used for startup notification of self.

New in version 2.2.

get_windows()
Returns:

the list of Wnck.Window belonging to self, or None if the application contains no window. The list should not be modified nor freed, as it is owned by self.

Return type:

[Wnck.Window]

Gets the list of Wnck.Window belonging to self.

get_xid()
Returns:

the X window ID of the group leader window for self.

Return type:

int

Gets the X window ID of the group leader window for self.

do_icon_changed() virtual
do_name_changed() virtual

Signal Details

Wnck.Application.signals.icon_changed(application)
Signal Name:

icon-changed

Flags:

RUN_LAST

Parameters:

application (Wnck.Application) – The object which received the signal

Emitted when the icon of app changes.

Wnck.Application.signals.name_changed(application)
Signal Name:

name-changed

Flags:

RUN_LAST

Parameters:

application (Wnck.Application) – The object which received the signal

Emitted when the name of app changes.