ImageMenuItem.newFromStock

Creates a new #GtkImageMenuItem containing the image and text from a stock item. Some stock ids have preprocessor macros like #GTK_STOCK_OK and #GTK_STOCK_APPLY.

If you want this menu item to have changeable accelerators, then pass in null for accel_group. Next call gtk.menu_item.MenuItem.setAccelPath with an appropriate path for the menu item, use gtk.global.stockLookup to look up the standard accelerator for the stock item, and if one is found, call gtk.accel_map.AccelMap.addEntry to register it.

More...
class ImageMenuItem
static
newFromStock

Parameters

stockId string

the name of the stock item.

accelGroup gtk.accel_group.AccelGroup

the #GtkAccelGroup to add the menu items accelerator to, or null.

Return Value

Type: gtk.image_menu_item.ImageMenuItem

a new #GtkImageMenuItem.

Detailed Description