gtk.ImageMenuItem.ImageMenuItem Class Reference

Inheritance diagram for gtk.ImageMenuItem.ImageMenuItem:

gtk.MenuItem.MenuItem gtk.Item.Item gtk.Bin.Bin gtk.Container.Container gtk.Widget.Widget gtk.ObjectGtk.ObjectGtk gobject.ObjectG.ObjectG List of all members.

Public Member Functions

GtkImageMenuItemgetImageMenuItemStruct ()
 this (GtkImageMenuItem *gtkImageMenuItem)
 Sets our main struct and passes it to the parent class.
 this (char[] label, bit mnemonic=true)
 Creates a new GtkImageMenuItem containing a label.
void setImage (Widget image)
 Sets the image of image_menu_item to the given widget.
Widget getImage ()
 Gets the widget that is currently set as the image of image_menu_item.
 this ()
 Creates a new GtkImageMenuItem with an empty label.
 this (char[] stockId, AccelGroup accelGroup)
 Creates a new GtkImageMenuItem containing the image and text from a stock item.

Protected Member Functions

void * getStruct ()
 the main Gtk struct as a void*

Protected Attributes

GtkImageMenuItemgtkImageMenuItem
 the main Gtk struct

Constructor & Destructor Documentation

gtk.ImageMenuItem.ImageMenuItem.this ( GtkImageMenuItem gtkImageMenuItem  ) 

Sets our main struct and passes it to the parent class.

gtk.ImageMenuItem.ImageMenuItem.this ( char[]  label,
bit  mnemonic = true 
)

Creates a new GtkImageMenuItem containing a label.

If mnemonic it true the label will be created using gtk_label_new_with_mnemonic(), so underscores in label indicate the mnemonic for the menu item. label: the text of the menu item. Returns: a new GtkImageMenuItem.

Reimplemented from gtk.MenuItem.MenuItem.

gtk.ImageMenuItem.ImageMenuItem.this (  ) 

Creates a new GtkImageMenuItem with an empty label.

Returns: a new GtkImageMenuItem.

gtk.ImageMenuItem.ImageMenuItem.this ( char[]  stockId,
AccelGroup  accelGroup 
)

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_set_accel_path() with an appropriate path for the menu item, use gtk_stock_lookup() to look up the standard accelerator for the stock item, and if one is found, call gtk_accel_map_add_entry() to register it. stock_id: the name of the stock item. accel_group: the GtkAccelGroup to add the menu items accelerator to, or NULL. Returns: a new GtkImageMenuItem.


Member Function Documentation

Widget gtk.ImageMenuItem.ImageMenuItem.getImage (  ) 

Gets the widget that is currently set as the image of image_menu_item.

See gtk_image_menu_item_set_image(). image_menu_item: a GtkImageMenuItem. Returns: the widget set as image of image_menu_item.

GtkImageMenuItem* gtk.ImageMenuItem.ImageMenuItem.getImageMenuItemStruct (  ) 

void* gtk.ImageMenuItem.ImageMenuItem.getStruct (  )  [protected]

the main Gtk struct as a void*

Reimplemented from gtk.MenuItem.MenuItem.

void gtk.ImageMenuItem.ImageMenuItem.setImage ( Widget  image  ) 

Sets the image of image_menu_item to the given widget.

Note that it depends on the show-menu-images setting whether the image will be displayed or not. image_menu_item: a GtkImageMenuItem. image: a widget to set as the image for the menu item.


Member Data Documentation

GtkImageMenuItem* gtk.ImageMenuItem.ImageMenuItem.gtkImageMenuItem [protected]

the main Gtk struct


SourceForge.net Logo DSource.org Logo digitalmars.com Logo