> For the complete documentation index, see [llms.txt](https://bkortbus.gitbook.io/unreal-python-recipe-book/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bkortbus.gitbook.io/unreal-python-recipe-book/editor-menus/discovering-menus-to-extend.md).

# Discovering Menus to Extend

How to find what Menus can be extended

Before we dive into any code let's discover what menus can be extended! In the Output Log Window, with `Cmd` set, we can run this command to enable an edit/debug state on any valid menu panels:

```java
ToolMenus.Edit 1
```

With this cvar set an additional cog button will be added to any menus that we can extend (marked in <mark style="color:green;">green</mark>):

<figure><img src="https://368271246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FStUBkBT2qJGKNkIZ6yc7%2Fuploads%2FjsDPwH1vS68k7nSrisKV%2Fimage.png?alt=media&amp;token=65b5e1ad-a621-401c-a4aa-36e5a96c01d9" alt=""><figcaption></figcaption></figure>

Anywhere we see that Cog is a Menu we can extend. Pressing on the Cog Button will open up this menu, providing us details on that menu:

<figure><img src="https://368271246-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FStUBkBT2qJGKNkIZ6yc7%2Fuploads%2FnP586IJNXYrYzmxN0A5b%2Fimage.png?alt=media&amp;token=1c306183-e2e4-4557-a566-86f955584e63" alt=""><figcaption></figcaption></figure>

This window is fantastic for our needs to determine the menu paths and what's already present. In this window we can find the available menus' paths, see what sections are available to add to, and make sure we don't add any duplicate menu names.

Here's a breakdown of the noted areas in the above screenshot:

1\)  the menu name / path. We can use this to find the menu in Python!\
2\) the menu contents, click on any entry here to view its details\
3\) the name of the selected menu item\
4\) the class type of the selected menu item
