public class MenuItem:
Single menu entry.
Subclasses may override click to implement actions while keeping the menu infrastructure generic.
item = MenuItem("Open...")| Modifier and Type | Member | Description |
|---|---|---|
| public property | iconicon as String = "" |
Short visual marker drawn before the menu text. |
| public property | isEnabledisEnabled as Boolean = true |
Whether the entry can be selected and activated. |
| public property | isSeparatorisSeparator as Boolean = false |
Whether this entry is a visual separator between action groups. |
| public property | shortcutshortcut as String = "" |
Human-readable shortcut displayed at the right of the menu item. |
| public property | subMenusubMenu as Menu = null |
Child menu opened from this item. |
| public property | texttext as String = "" |
Display text shown in the menu popup. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | MenuItem | Creates a menu item. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | clickclick() as Void: |
Executes the menu action. |