How to put external tools in their own menu in main menu bar?

I have defined a number of external tools. I would like to create my own menu in the main menu bar across the top of the IDEA GUI, and then put my external tool entries in that menu (instead of having them under the "Tools" menu). Any ideas on how to do that?

I've seen the following in plugin.xml files, maybe I can use this but I don't know what the action id would be for each external tool.

]]>

1 comment

To solve this, I ended up creating the new menu and submenus programmatically using the ActionGroup and ActionManager classes. I figured out that the the action id for an external tool is:

"Tool__]]>"

So if there is an external tool called "Do The Right Thing" in a group called "Stuff", then the action id is:

"Tool_Stuff_Do The Right Thing"

Using this action id, it's possible to retrieve the AnAction object for any external tool from the ActionManager and then stick it into a menu, run the tool, etc.

0

Please sign in to leave a comment.