gtk.numerable_icon

Module for [NumerableIcon] class

Types 3

GtkNumerableIcon is a subclass of #GEmblemedIcon that can show a number or short string as an emblem. The number can be overlayed on top of another emblem, if desired.

It supports theming by taking font and color information from a provided #GtkStyleContext; see [gtk.numerable_icon.NumerableIcon.setStyleContext].

Typical numerable icons: ![](numerableicon.png) ![](numerableicon2.png)

Methods
GType _gType() @property
NumerableIcon self()Returns `this`, for use in `with` statements.
NumerableIconGidBuilder builder()Get builder for [gtk.numerable_icon.NumerableIcon] Returns: New builder object
void backgroundIcon(gio.icon.Icon propval) @property
string backgroundIconName() @property
void backgroundIconName(string propval) @property
int count() @property
void count(int propval) @property
string label() @property
void label(string propval) @property
gio.icon.Icon new_(gio.icon.Icon baseIcon)Creates a new unthemed #GtkNumerableIcon.
gio.icon.Icon newWithStyleContext(gio.icon.Icon baseIcon, gtk.style_context.StyleContext context)Creates a new #GtkNumerableIcon which will themed according to the passed #GtkStyleContext. This is a convenience constructor that calls [gtk.numerable_icon.NumerableIcon.setStyleContext] internally.
gio.icon.Icon getBackgroundGicon()Returns the #GIcon that was set as the base background image, or null if there’s none. The caller of this function does not own a reference to the returned #GIcon. Returns: a #GIcon, or null
string getBackgroundIconName()Returns the icon name used as the base background image, or null if there’s none. Returns: an icon name, or null
int getCount()Returns the value currently displayed by self. Returns: the currently displayed value
string getLabel()Returns the currently displayed label of the icon, or null. Returns: the currently displayed label
gtk.style_context.StyleContext getStyleContext()Returns the #GtkStyleContext used by the icon for theming, or null if there’s none. Returns: a #GtkStyleContext, or null. This object is internal to GTK+ and should not be unreffed. Use [gobject....
void setBackgroundGicon(gio.icon.Icon icon = null)Updates the icon to use icon as the base background image. If icon is null, self will go back using style information or default theming for its background image.
void setBackgroundIconName(string iconName = null)Updates the icon to use the icon named iconname from the current icon theme as the base background image. If iconname is null, self will go back using style information or default theming for its b...
void setCount(int count)Sets the currently displayed value of self to count.
void setLabel(string label = null)Sets the currently displayed value of self to the string in label. Setting an empty label removes the emblem.
void setStyleContext(gtk.style_context.StyleContext style)Updates the icon to fetch theme information from the given #GtkStyleContext.
Constructors
this(void * ptr, Flag!"Take" take)

Fluent builder for [gtk.numerable_icon.NumerableIcon]