API ReferenceEditor
Menuclass
Constructors2
Showing 2 constructors
No results match this filter.
Methods31
Showing 31 methods
public Editor.Label AddHeading(string title)
| Parameter | Type | Description |
|---|---|---|
| title | string | — |
public virtual Editor.Option AddOptionWithImage(string name, Editor.Pixmap icon, System.Action action = null, string shortcut = null)
| Parameter | Type | Description |
|---|---|---|
| name | string | — |
| icon | Pixmap | — |
| action = null | Action | — |
| shortcut = null | string | — |
public T AddWidget(T widget)
Add a widget as an action to the menu. Some widgets such as `Editor.Widget` and `Editor.LineEdit` require `Editor.Widget.OnMouseReleased(Editor.MouseEvent)` to set `Editor.MouseEvent.Accepted` to to prevent the menu from closing.
| Parameter | Type | Description |
|---|---|---|
| widget | T | — |
Returns:
T—public void Clear()
Returns:
void—protected virtual void OnAboutToHide()
Returns:
void—protected virtual void OnAboutToShow()
Returns:
void—public void OpenAt(Vector2 position, bool modal = True)
| Parameter | Type | Description |
|---|---|---|
| position | Vector2 | — |
| modal = True | bool | — |
Returns:
void—public void OpenAtCursor(bool modal = False)
Open this menu at the mouse cursor position
| Parameter | Type | Description |
|---|---|---|
| modal = False | bool | — |
Returns:
void—public void RemoveMenus()
Remove all menus
Returns:
void—public void RemoveOptions()
Remove all options
Returns:
void—public void RemoveWidgets()
Remove all widgets
Returns:
void—No results match this filter.
Properties12
Showing 12 properties
public bool Editor.Menu.HasMenus { get; set; }
Returns:
bool—public bool Editor.Menu.HasOptions { get; set; }
Returns:
bool—public string Editor.Menu.Icon { get; set; }
Returns:
string—public int Editor.Menu.MenuCount { get; set; }
Returns:
int—public int Editor.Menu.OptionCount { get; set; }
Returns:
int—public virtual string Editor.Menu.ToolTip { get; set; }
Returns:
string—public bool Editor.Menu.ToolTipsVisible { get; set; }
This property holds whether tooltips of menu actions should be visible. This property specifies whether action menu entries show their tooltip. By default, this property is `false`.
Returns:
bool—No results match this filter.