|
libui
A portable GUI library for C
|
A menu item used in conjunction with uiMenu.
#include <ui.h>
Public Member Functions | |
| void | uiMenuItemEnable (uiMenuItem *m) |
| Enables the menu item. | |
| void | uiMenuItemDisable (uiMenuItem *m) |
| Disables the menu item. | |
| void | uiMenuItemOnClicked (uiMenuItem *m, void(*f)(uiMenuItem *sender, uiWindow *window, void *senderData), void *data) |
| Registers a callback for when the menu item is clicked. | |
| int | uiMenuItemChecked (uiMenuItem *m) |
| Returns whether or not the menu item's checkbox is checked. | |
| void | uiMenuItemSetChecked (uiMenuItem *m, int checked) |
| Sets whether or not the menu item's checkbox is checked. | |
| int uiMenuItemChecked | ( | uiMenuItem * | m | ) |
Returns whether or not the menu item's checkbox is checked.
To be used only with items created via uiMenuAppendCheckItem().
| m | uiMenuItem instance. |
TRUE if checked, FALSE otherwise. [Default: FALSE] | void uiMenuItemDisable | ( | uiMenuItem * | m | ) |
Disables the menu item.
Menu item is grayed out and user interaction is not possible.
| m | uiMenuItem instance. |
| void uiMenuItemEnable | ( | uiMenuItem * | m | ) |
Enables the menu item.
| m | uiMenuItem instance. |
| void uiMenuItemOnClicked | ( | uiMenuItem * | m, |
| void(* | f )(uiMenuItem *sender, uiWindow *window, void *senderData), | ||
| void * | data ) |
Registers a callback for when the menu item is clicked.
| m | uiMenuItem instance. |
| f | Callback function.sender Back reference to the instance that triggered the callback.window Reference to the window from which the callback got triggered.\ senderData User data registered with the sender instance. |
| data | User data to be passed to the callback. |
| void uiMenuItemSetChecked | ( | uiMenuItem * | m, |
| int | checked ) |
Sets whether or not the menu item's checkbox is checked.
To be used only with items created via uiMenuAppendCheckItem().
| m | uiMenuItem instance. |
| checked | TRUE to check menu item checkbox, FALSE otherwise. |