emailapplescriptshortcutkey-bindingsapple-mail

Apple Mail "Show Related Messages" Script for Hotkey


I'm usually a Gmail user but on my most recent gig have to use an Exchange account and so decided to give Apple Mail another try (after looking at a bunch of other options) but I digress.

I prefer the classic layout but don't like to group messages by conversation.

I'm looking for a way/script to use the "Show Related Messages" button, which you can add to the toolbar, so that I can bind it to a shortcut so I can quickly catch up on emails using no mouse clicks.

Is this possible or am I hoping for something not doable?

I'm running El Capitan in case that's an issue.

Thanks for your time!


Solution

  • If I'm understanding you correctly, you essentially want a keyboard shortcut to access the menu item Show Related Messages in the Mail application. You mention adding something to the toolbar, but then also say you don't wish to use any mouse clicks, so I'm going to assume that it doesn't really matter whether or not there's a shortcut on the toolbar—that your priority is using the keyboard to turn on/off the Show Related Messages option.

    I'm using MacOS High Sierra, so my screenshots may look a little bit different to what you see on your system, but the process for El Capitan is the same or very similar.

    Open up System Preferences and selected the Keyboard pane. In the left-hand list, select App Shortcuts:

    App Shortcuts in MacOS High Sierra

    Then click the + button to the right in order to create a new shortcut:

    Create New App Shortcut on MacOS High Sierra

    Choose the Mail application from the dropdown list, and enter the menu item for which you want the shortcut to apply; in this case, Show Related Messages. Note: It must be typed in exactly, including any capital letters that feature, and without any extra spaces that aren't appropriate. For example, "Show related messages" will not work.

    Finally, highlight the Keyboard Shortcut box and press the key combo that you'd like to use as your shortcut. You can even use one that's already assigned in Mail to something else; the pre-existing shortcut will automatically get reassigned where possible.

    Click the Add button.

    From then on, you'll be able to use your shortcut to toggle the Show Related Messages option on/off.