#define OMTK_EVENT_DID_CLICK
This event is called when you activate a menu item. You shouldn't use this event on menu items with a submenu.
OmtkWidget *omtk_menuitem_create(char *label);
Returns a new menu item with a label.
void omtk_menuitem_submenu_set(OmtkWidget *item, OmtkWidget *menu);
Sets the submenu of item to menu. If menu is NULL, the submenu of item will be removed.
Note: You may not change the submenu of a top-level menu item (which is e.g. "File", "Edit", etc. in a typical menubar).
OmtkWidget *omtk_menuitem_submenu_get(OmtkWidget *item);
Returns the submenu which was set with omtk_menuitem_submenu_set(). Returns NULL, if the item has no submenu.
void omtk_menuitem_label_set(OmtkWidget *item, char *label);
Sets the label of a menu item to label.
char *omtk_menuitem_label_get(OmtkWidget *item);
Returns the label of a menu item.
void omtk_menuitem_shortcut_set(OmtkWidget *item, unsigned short modifier, \ unsigned short key);
Sets the shortcut of the menu item. See OMTK_KEY_* for the modifier and the key.
You can combine the modifier keys, e.g.:
omtk_menuitem_shortcut_set(item_file_save_as, OMTK_KEY_CTRL | OMTK_KEY_SHIFT, OMTK_KEY_S);
void omtk_menuitem_free(OmtkWidget *widget);
Frees the menu item. Do not call this function directly.
Zurück zu www.eggdrop.ch | Back to www.eggdrop.ch Last update: 20.02.04 |
Copyright (C) 2004, 2005 by Thomas "tom" Steinacher <tom at eggdrop.ch> |