-
Notifications
You must be signed in to change notification settings - Fork 0
class_popupmenu
reduz edited this page Feb 23, 2014
·
10 revisions
Inherits: Popup\n\n### Brief Description
PopupMenu displays a list of options.
- void add_icon_item" ( Object texture, String label, int id=-1, int accel=0 )
- void add_item" ( String label, int id=-1, int accel=0 )
- void add_icon_check_item" ( Object texture, String label, int id=-1, int accel=0 )
- void add_check_item" ( String label, int id=-1, int accel=0 )
- void add_submenu_item" ( String label, int submenu, int id=-1 )
- void set_item_text" ( int idx, String text )
- void set_item_icon" ( int idx, Object icon )
- void set_item_accelerator" ( int idx, int accel )
- void set_item_metadata" ( int idx, var metadata )
- void set_item_checked" ( int idx, bool arg1 )
- void set_item_disabled" ( int idx, bool disabled )
- void set_item_submenu" ( int idx, String submenu )
- void set_item_as_separator" ( int idx, bool enable )
- void set_item_as_checkable" ( int idx, bool enable )
- void set_item_ID" ( int idx, int id )
- String get_item_text" ( int idx ) const
- Object get_item_icon" ( int idx ) const
- void get_item_metadata" ( int idx ) const
- int get_item_accelerator" ( int idx ) const
- String get_item_submenu" ( int idx ) const
- bool is_item_separator" ( int idx ) const
- bool is_item_checkable" ( int idx ) const
- bool is_item_checked" ( int idx ) const
- bool is_item_disabled" ( int idx ) const
- int get_item_ID" ( int idx ) const
- int get_item_index" ( int id ) const
- int get_item_count" ( ) const
- void add_separator" ( )
- void remove_item" ( int idx )
- void clear" ( )
- item_pressed ( int ID )
PopupMenu is the typical Control that displays a list of options. They are popular in toolbars or context menus.
== add_icon_item ==
- void add_icon_item" ( Object texture, String label, int id=-1, int accel=0 ) \ Add a new item with text "label" and icon "texture. An id can optonally be provided, as well as an accelerator. If no id is provided, one will be created from the index. == add_item ==
- void add_item" ( String label, int id=-1, int accel=0 ) \ Add a new item with text "label". An id can optonally be provided, as well as an accelerator. If no id is provided, one will be created from the index. == add_icon_check_item ==
- void add_icon_check_item" ( Object texture, String label, int id=-1, int accel=0 ) \ Add a new checkable item with text "label" and icon "texture. An id can optonally be provided, as well as an accelerator. If no id is provided, one will be created from the index. Note that checkable items just display a checkmark, but don"apos;t have any built-in checking behavior and must be checked/unchecked manually. == add_check_item ==
- void add_check_item" ( String label, int id=-1, int accel=0 ) \ Add a new checkable item with text "label". An id can optonally be provided, as well as an accelerator. If no id is provided, one will be created from the index. Note that checkable items just display a checkmark, but don"apos;t have any built-in checking behavior and must be checked/unchecked manually. == set_item_text ==
- void set_item_text" ( int idx, String text ) \ Set the text of the item at index "idx". == set_item_icon ==
- void set_item_icon" ( int idx, Object icon ) \ Set the icon of the item at index "idx". == set_item_accelerator ==
- void set_item_accelerator" ( int idx, int accel ) \ Set the accelerator of the item at index "idx". Accelerators are special combinations of keys that activate the item, no matter which control is fucused. == set_item_checked ==
- void set_item_checked" ( int idx, bool arg1 ) \ Set the checkstate status of the item at index "idx". == set_item_ID ==
- void set_item_ID" ( int idx, int id ) \ Set the id of the item at index "idx". == get_item_text ==
- String get_item_text" ( int idx ) const \ Return the text of the item at index "idx". == get_item_icon ==
- Object get_item_icon" ( int idx ) const \ Return the icon of the item at index "idx". == get_item_accelerator ==
- int get_item_accelerator" ( int idx ) const \ Return the accelerator of the item at index "idx". Accelerators are special combinations of keys that activate the item, no matter which control is fucused. == is_item_checked ==
- bool is_item_checked" ( int idx ) const \ Return the checkstate status of the item at index "idx". == get_item_ID ==
- int get_item_ID" ( int idx ) const \ Return the id of the item at index "idx". == get_item_index ==
- int get_item_index" ( int id ) const \ Find and return the index of the item containing a given id. == get_item_count ==
- int get_item_count" ( ) const \ Return the amount of items. == add_separator ==
- void add_separator" ( ) \ Add a separator between items. Separators also occupy an index. == clear ==
- void clear" ( ) \ Clear the popup menu.