> For the complete documentation index, see [llms.txt](https://kinematicsoup.gitbook.io/reactor/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kinematicsoup.gitbook.io/reactor/api-reference/ks.unity.editor/ks.unity.editor.ksimenu.md).

# Interface ksIMenu

Namespace: [KS.Unity.Editor](/reactor/api-reference/ks.unity.editor.md)\
Assembly: KSUnity-Editor.dll

Menu interface for creating GUIs for the [ksWindow](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kswindow.md) class.

```csharp
public interface ksIMenu
```

## Properties

### DestroyOnClose <a href="#ks_unity_editor_ksimenu_destroyonclose" id="ks_unity_editor_ksimenu_destroyonclose"></a>

Should we destroy this menu when it is closed?

```csharp
bool DestroyOnClose { get; }
```

#### Property Value

[bool](https://learn.microsoft.com/dotnet/api/system.boolean)

### Icon <a href="#ks_unity_editor_ksimenu_icon" id="ks_unity_editor_ksimenu_icon"></a>

The icon for this menu.

```csharp
Texture Icon { get; }
```

#### Property Value

Texture

## Methods

### Draw(ksWindow) <a href="#ks_unity_editor_ksimenu_draw_ks_unity_editor_kswindow" id="ks_unity_editor_ksimenu_draw_ks_unity_editor_kswindow"></a>

Draws the GUI.

```csharp
void Draw(ksWindow window)
```

#### Parameters

`window` [ksWindow](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kswindow.md)

window to create the GUI for.

### OnClose(ksWindow) <a href="#ks_unity_editor_ksimenu_onclose_ks_unity_editor_kswindow" id="ks_unity_editor_ksimenu_onclose_ks_unity_editor_kswindow"></a>

Called when the menu is closed.

```csharp
void OnClose(ksWindow window)
```

#### Parameters

`window` [ksWindow](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kswindow.md)

window that closed the menu.

### OnOpen(ksWindow) <a href="#ks_unity_editor_ksimenu_onopen_ks_unity_editor_kswindow" id="ks_unity_editor_ksimenu_onopen_ks_unity_editor_kswindow"></a>

Called when the menu is opened.

```csharp
void OnOpen(ksWindow window)
```

#### Parameters

`window` [ksWindow](/reactor/api-reference/ks.unity.editor/ks.unity.editor.kswindow.md)

window that opened the menu.
