Earlier quoted context omitted.
Yep this is what I came to say - OSX's help menu automatically searches all menu commands and if you hover over them it will open up the menu, show you the location, and if you hit enter just use it for you. This is also something you can generally call from Applescript as well, if you want to automate application behaviors.
Mind sharing an example AppleScript of that? Every time I’ve dug in there, it’s never had quite what I wanted. But this seems like an especially leverage-able idea.
I am pretty sure most of the work was just extending the documentation in https://developer.apple.com/library/archive/documentation/La... with looking up application "dictionaries" (iirc, a box of supported commands) and all menu items being accessible by default.
https://developer.apple.com/library/archive/documentation/Ap...