Constructor

GtkButtonnew_from_icon_name

since: 3.10

Declaration [src]

GtkWidget*
gtk_button_new_from_icon_name (
  const gchar* icon_name,
  GtkIconSize size
)

Description [src]

Creates a new button containing an icon from the current icon theme.

If the icon name isn’t known, a “broken image” icon will be displayed instead. If the current icon theme is changed, the icon will be updated appropriately.

This function is a convenience wrapper around gtk_button_new() and gtk_button_set_image().

Available since: 3.10

Parameters

icon_name

Type: const gchar*

An icon name or NULL.

The argument can be NULL.
The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.
size

Type: GtkIconSize

An icon size (GtkIconSize)

Return value

Type: GtkWidget

A new GtkButton displaying the themed icon.

The data is owned by the called function.