How to Select a Menu Item From a Pallet in Adobe InDesign

I use Adobe Indesign to design newspaper pages. Many menu items tunnel into submenus and from there into panels. Is there any way to get a macro to select a menu item from a panel? I've tried the Select Menu item option but the panel menu items don't appear. I'm very much a newbie to KM, but I can't find anything that would apply to this. Is there another utility that would work better.

Ideas much appreciated.

Hi @graphicsgeezer
I use Adobe Illustrator daily and InDesign (not so much) and have managed to get Keyboard Maestro to speed up a lot of this stuff. As InDesign and Illustrator are both by Adobe I suspect a lot of the Palette Stuff is similar and equally fiddly to access and automate. But I have been successful in most of the things I have tried - so, I am sure there will be ways Keyboard Maestro can speed up your workflow.

Could you give an exact example of one task you would like to automate (the Palette, Sub-Menu etc that you can't access)?

I am assuming you mean something like this (a sub menu of the Color Palette in InDesign):

The first stop is find out if any of this stuff can be accessed by obscure keyboard shortcuts and then use Keyboard Maestro to press those shortcuts for you. A search on Google will find lists of these shortcuts.

A second Approach is to see if you can make an Action in InDesign (in effect an InDesign Macro) and invoke this Action using Keyboard Maestro (this has worked very well for me with Illustrator).

A third approach is to do a Google Search for any AppleScripts that might do what you want and again use Keyboard Maestro to invoke them.

And, if all else fails, you can use Keyboard Maestro's ability to click on a Found Image to bring up the Dropdown Menu from the palette and then get Keyboard Maestro to type the name of the menu item you want. Basically automating your mouse movements and clicks.

Anyway, a few ideas to get you started.


Adobe apps have a lot of keyboard shortcuts, InDesign specially. As Zabobon commented, check in InDesign if there's a way to set a keyboard shortcut.

If there's no direct access, a quick solution is to use a mix of Select Menu actions and Click at Found Image actions.


Thanks for your help-- I'll definitely try your ideas out. But you've more or less told me that KM won't select such menu items directly without recording mouse movements, which won't work because panels change positions from time to time. Is there anything out there that would work better?

That is where "Click at Found Image" comes into play. The Macro can be set to move the mouse to the palette and click at the spot to reveal the sub menu. You need to make sure the image chosen to click at is unique to that palette (as many palettes will look the same). So, something like this:

You might have this as the Image to Find:

And get Keyboard Maestro to click here to reveal the dropdown menu:


I second @zabodon's reply: Click At Found Image is not recording mouse coordinates; it's looking for an image onscreen--in this case, InDesign's panel flyout menu--and then clicking on that, wherever it happens to be. I've used Keyboard Maestro for several years now to automate InDesign, InCopy, Illustrator, Photoshop, Acrobat, and other applications through Click At Found Image.


Thanks you guys-- that's very encouraging!

To get you started, here is a breakdown of a Macro I use in Adobe Illustrator to toggle Scale Strokes and Effects on and off (there is no built in shortcut for this and I have to do it all the time). It might give an idea of how to build your own Macros using Keyboard Maestro's extremely flexible modular syststem of just stringing Actions together until you get something that works.

First the whole Macro (and then notes on what each Action does and why it is there):

Scale Strokes and Effects [EXAMPLE].kmmacros (50.2 KB)

This first Action opens the Palette I want. (As Illustrator has the same Menu Command to open and close the Palette I have had to add a condition that the Menu Item is Marked (has a tick next to it) otherwise this Action would close the Palette if it was already open). This is actually the most fiddly bit in the whole macro - after this step it gets much simpler.


The next Action moves and clicks the Mouse where it needs to on the Palette (The image is an area Screengrab of the top of the Palette just pasted into Keyboard Maestro's Image Well). The coordinates 110 and 0 I found by experimenting.

Here is the Screengrab I pasted into that Image Well:


The next Action Types a right arrow which opens the Menu.

The next Action Types the start of the Menu Item I want to select and Highlights that item on the Menu

The last Action types the Return key, in effect activating the Menu Item.

One other thing to be aware of when building these Macros is that sometimes it can help to have a tiny pause between Actions to give the System time to catch up with each Action. In the above example I found it works without any pauses - but that would be my first debug if it stopped working as expected.

1 Like

thanks, great writeup Zabobon.

Honestly, very surprised. Was going to ask exactly that, seems like Adobe has a very responsive interface.

1 Like

It might also depend on the actual Mac that is running the Adobe Apps and how fast the Mac is. Anyway, Pauses seem to sort out most problems :smiling_face:

1 Like

I didn't know about the Is Marked condition. Your Illustrator example just solved an annoying frustration I have with an Adobe Audition macro. Thank you!

1 Like

I use Pauses for troubleshooting and testing frequently.

Yes, it took me ages to work that one out. Of course in most cases it is good that the same command toggles the panel on and off.


This is a very helpful discussion. I'm too much of a newbie to be able to follow your instructions exactly, but I found a good elementary tutorial here: Keyboard Maestro 202: Mouse Clicks - YouTube

Hi everyone.

You can also call submenus/functions with javascript!
Read these very interesting pages:

With the InDesign script provided by Peter Kharel, you can get the menuIDs of many functions not all accessible:

Then you just have to invoke them in Javascript (through Applescript otherwise it doesn't work directly with Keyboard Mestro) like this for example:

tell application id "com.adobe.InDesign"
    do script "app.menuActions.itemByID(27139).invoke();" language javascript
end tell

or another method (by name):

tell application id "com.adobe.InDesign"
    do script "try {app.menuActions.item("Convert to Grayscale").invoke(); } catch(e) {};" language javascript
end tell