Learn R Programming

RGtk2 (version 2.20.31)

gtkToolbarAppendItem: gtkToolbarAppendItem

Description

Inserts a new item into the toolbar. You must specify the position in the toolbar where it will be inserted. WARNING: gtk_toolbar_append_item has been deprecated since version 2.4 and should not be used in newly-written code. Use gtkToolbarInsert instead.

Usage

gtkToolbarAppendItem(object, text, tooltip.text, tooltip.private.text, icon, callback, user.data = NULL)

Arguments

object
text
give your toolbar button a label.
tooltip.text
a string that appears when the user holds the mouse over this item.
tooltip.private.text
use with GtkTipsQuery.
icon
a GtkWidget that should be used as the button's icon.
callback
the function to be executed when the button is pressed.
user.data
a pointer to any data you wish to be passed to the callback.

Value

GtkWidget] the new toolbar item as a GtkWidget.

Details

callback must be a pointer to a function taking a GtkWidget and a gpointer as arguments. Use gCallback() to cast the function to GCallback.