StatusIcon


Object Hierarchy:

Gtk.StatusIcon Gtk.StatusIcon Gtk.StatusIcon GLib.Object GLib.Object GLib.Object->Gtk.StatusIcon

Description:

[ CCode ( type_id = "gtk_status_icon_get_type ()" ) ]
[ Version ( deprecated = true , deprecated_since = "3.14" ) ]
public class StatusIcon : Object

Warning: StatusIcon is deprecated since 3.14.

The “system tray” or notification area is normally used for transient icons that indicate some special state.

For example, a system tray icon might appear to tell the user that they have new mail, or have an incoming instant message, or something along those lines. The basic idea is that creating an icon in the notification area is less annoying than popping up a dialog.

A StatusIcon object can be used to display an icon in a “system tray”. The icon can have a tooltip, and the user can interact with it by activating it or popping up a context menu.

It is very important to notice that status icons depend on the existence of a notification area being available to the user; you should not use status icons as the only way to convey critical information regarding your application, as the notification area may not exist on the user's environment, or may have been removed. You should always check that a status icon has been embedded into a notification area by using is_embedded, and gracefully recover if the function returns false.

On X11, the implementation follows the FreeDesktop System Tray Specification. Implementations of the “tray” side of this specification can be found e.g. in the GNOME 2 and KDE panel applications.

Note that a GtkStatusIcon is not a widget, but just a Object. Making it a widget would be impractical, since the system tray on Windows doesn’t allow to embed arbitrary widgets.

GtkStatusIcon has been deprecated in 3.14. You should consider using notifications or more modern platform-specific APIs instead. GLib provides the Notification API which works well with Application on multiple platforms and environments, and should be the preferred mechanism to notify the users of transient status updates. See this HowDoI for code examples.


Namespace: Gtk
Package: gtk+-3.0

Content:

Properties:

Creation methods:

Methods:

Signals:

Inherited Members: