Connect to Activate signal.
Connect to ButtonPressEvent signal.
Connect to ButtonReleaseEvent signal.
Connect to PopupMenu signal.
Connect to QueryTooltip signal.
Connect to ScrollEvent signal.
Connect to SizeChanged signal.
Obtains information about the location of the status icon on screen. This information can be used to e.g. position popups like notification bubbles.
Retrieves the #GIcon being displayed by the #GtkStatusIcon. The storage type of the status icon must be gtk.types.ImageType.Empty or gtk.types.ImageType.Gicon (see gtk.status_icon.StatusIcon.getStorageType). The caller of this function does not own a reference to the returned #GIcon.
Returns the current value of the has-tooltip property. See #GtkStatusIcon:has-tooltip for more information.
Gets the name of the icon being displayed by the #GtkStatusIcon. The storage type of the status icon must be gtk.types.ImageType.Empty or gtk.types.ImageType.IconName (see gtk.status_icon.StatusIcon.getStorageType). The returned string is owned by the #GtkStatusIcon and should not be freed or modified.
Gets the #GdkPixbuf being displayed by the #GtkStatusIcon. The storage type of the status icon must be gtk.types.ImageType.Empty or gtk.types.ImageType.Pixbuf (see gtk.status_icon.StatusIcon.getStorageType). The caller of this function does not own a reference to the returned pixbuf.
Returns the #GdkScreen associated with status_icon.
Gets the size in pixels that is available for the image. Stock icons and named icons adapt their size automatically if the size of the notification area changes. For other storage types, the size-changed signal can be used to react to size changes.
Gets the id of the stock icon being displayed by the #GtkStatusIcon. The storage type of the status icon must be gtk.types.ImageType.Empty or gtk.types.ImageType.Stock (see gtk.status_icon.StatusIcon.getStorageType). The returned string is owned by the #GtkStatusIcon and should not be freed or modified.
Gets the type of representation being used by the #GtkStatusIcon to store image data. If the #GtkStatusIcon has no image data, the return value will be gtk.types.ImageType.Empty.
Gets the title of this tray icon. See gtk.status_icon.StatusIcon.setTitle.
Gets the contents of the tooltip for status_icon.
Gets the contents of the tooltip for status_icon.
Returns whether the status icon is visible or not. Note that being visible does not guarantee that the user can actually see the icon, see also gtk.status_icon.StatusIcon.isEmbedded.
This function is only useful on the X11/freedesktop.org platform.
Returns whether the status icon is embedded in a notification area.
Returns this, for use in with statements.
Makes status_icon display the file filename. See gtk.status_icon.StatusIcon.newFromFile for details.
Makes status_icon display the #GIcon. See gtk.status_icon.StatusIcon.newFromGicon for details.
Makes status_icon display the icon named icon_name from the current icon theme. See gtk.status_icon.StatusIcon.newFromIconName for details.
Makes status_icon display pixbuf. See gtk.status_icon.StatusIcon.newFromPixbuf for details.
Makes status_icon display the stock icon with the id stock_id. See gtk.status_icon.StatusIcon.newFromStock for details.
Sets the has-tooltip property on status_icon to has_tooltip. See #GtkStatusIcon:has-tooltip for more information.
Sets the name of this tray icon. This should be a string identifying this icon. It is may be used for sorting the icons in the tray and will not be shown to the user.
Sets the #GdkScreen where status_icon is displayed; if the icon is already mapped, it will be unmapped, and then remapped on the new screen.
Sets the title of this tray icon. This should be a short, human-readable, localized string describing the tray icon. It may be used by tools like screen readers to render the tray icon.
Sets markup as the contents of the tooltip, which is marked up with the [Pango text markup language]PangoMarkupFormat.
Sets text as the contents of the tooltip.
Shows or hides a status icon.
Get embedded property.
Get gicon property.
Set gicon property.
Get hasTooltip property.
Set hasTooltip property.
Get orientation property.
Get title property.
Set title property.
Get tooltipMarkup property.
Set tooltipMarkup property.
Get tooltipText property.
Set tooltipText property.
Get builder for gtk.status_icon.StatusIcon
Creates a status icon displaying the file filename.
Creates a status icon displaying a #GIcon. If the icon is a themed icon, it will be updated when the theme changes.
Creates a status icon displaying an icon from the current icon theme. If the current icon theme is changed, the icon will be updated appropriately.
Creates a status icon displaying pixbuf.
Creates a status icon displaying a stock icon. Sample stock icon names are #GTK_STOCK_OPEN, #GTK_STOCK_QUIT. You can register your own stock icon names, see gtk.icon_factory.IconFactory.addDefault and gtk.icon_factory.IconFactory.add.
Menu positioning function to use with gtk.menu.Menu.popup to position menu aligned to the status icon user_data.
Set the GObject of a D ObjectWrap wrapper.
Get a pointer to the underlying C object.
Calls g_object_ref() on a GObject.
Calls g_object_unref() on a GObject.
Get the GType of an object.
GObject GType property.
Convenience method to return this cast to a type. For use in D with statements.
Template to get the D object from a C GObject and cast it to the given D object type.
Connect a D closure to an object signal.
Template for setting a GObject property.
Template for getting a GObject property.
Creates a binding between source_property on source and target_property on target.
Creates a binding between source_property on source and target_property on target, allowing you to set the transformation functions to be used by the binding.
This function is intended for #GObject implementations to re-enforce a floating[floating-ref] object reference. Doing this is seldom required: all #GInitiallyUnowneds are created with a floating reference which usually just needs to be sunken by calling gobject.object.ObjectWrap.refSink.
Increases the freeze count on object. If the freeze count is non-zero, the emission of "notify" signals on object is stopped. The signals are queued until the freeze count is decreased to zero. Duplicate notifications are squashed so that at most one #GObject::notify signal is emitted for each property modified while the object is frozen.
Gets a named field from the objects table of associations (see gobject.object.ObjectWrap.setData).
Gets a property of an object.
This function gets back user data pointers stored via gobject.object.ObjectWrap.setQdata.
Gets n_properties properties for an object. Obtained properties will be set to values. All properties must be valid. Warnings will be emitted and undefined behaviour may result if invalid properties are passed in.
Checks whether object has a floating[floating-ref] reference.
Emits a "notify" signal for the property property_name on object.
Emits a "notify" signal for the property specified by pspec on object.
Increase the reference count of object, and possibly remove the floating[floating-ref] reference, if object has a floating reference.
Releases all references to other objects. This can be used to break reference cycles.
Each object carries around a table of associations from strings to pointers. This function lets you set an association.
Sets a property on an object.
Remove a specified datum from the object's data associations, without invoking the association's destroy handler.
This function gets back user data pointers stored via gobject.object.ObjectWrap.setQdata and removes the data from object without invoking its destroy() function (if any was set). Usually, calling this function is only required to update user data pointers with a destroy notifier, for example:
Reverts the effect of a previous call to gobject.object.ObjectWrap.freezeNotify. The freeze count is decreased on object and when it reaches zero, queued "notify" signals are emitted.
This function essentially limits the life time of the closure to the life time of the object. That is, when the object is finalized, the closure is invalidated by calling gobject.closure.Closure.invalidate on it, in order to prevent invocations of the closure with a finalized (nonexisting) object. Also, gobject.object.ObjectWrap.ref_ and gobject.object.ObjectWrap.unref are added as marshal guards to the closure, to ensure that an extra reference count is held on object during invocation of the closure. Usually, this function will be called on closures that use this object as closure data.
Connect to Notify signal.
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 #GtkStatusIcon 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 gtk.status_icon.StatusIcon.isEmbedded, 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 #GObject. 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 #GNotification API which works well with #GtkApplication 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.