17.4 C
London
Friday, September 6, 2024

macos – How do I add, change or take away a key command from a menu merchandise?


You’ll be able to add a customized key command to nearly something that has a menu merchandise.
It would not matter the place the merchandise is within the hierarchy, except there are two gadgets with the identical title [which is rare.] You’ll be able to add instructions globally, to all apps which include that menu merchandise, or simply particularly to a single app – whichever you like.

All the time be sure you’re not utilizing a replica command already used for an additional perform, and do not attempt to use this as a one-stop answer to ‘repair’ Mac shortcuts to any you had been used to in Home windows… that by no means ends effectively 😉

Illustrations all on Mojave. I’ll add variants for Ventura after I can get entry for a day. Ventura is visually completely different, however the strategies are the identical.
Let’s use Export Bookmarks… from Safari as our primary instance, because it would not have already got a key command.

enter image description here

In System Choice > Keyboard > Shortcuts > App Shortcuts, click on the + button. If you have already got an entry for Safari, if you choose that previous to clicking + then it’s going to pre-populate the menu for you. You then add your menu title, precisely as written, transfer to the final field & press your chosen shortcut. It is going to be added to the menu as quickly as you click on Add.

enter image description here

enter image description here

Be aware that some macOS variations demand you employ an ellipsis … if the menu merchandise has one, some don’t. It is all the time smarter so as to add one anyway. You’ll be able to generate an ellipsis on an English keyboard utilizing Choose ⌥ ; [opt/semicolon].
Be aware that an ellipsis just isn’t the identical as three stops/intervals.

To switch any key command, use the above methodology & merely add your most well-liked new command, it’s going to immediately be swapped on your new set off.


You can not truly take away a key command that exists by default, however you can change it with a ‘rubbish’ command you’ll by no means want for the rest.

In Safari I by no means use the Studying record, however used to motion it by accident. Not any extra…

enter image description here

F19 solely exists on prolonged keyboards, however including all of the modifiers plus any key’s unlikely to generate any clashes, nor be hit by accident.


Modifier keys
You need to use any and all modifiers in any mixture, Cmd ⌘ Choose ⌥ Ctrl ⌃ Shift ⇧ . You can not use Shift alone, however you should use it together with any or the entire others.
macOS doesn’t differentiate between left and proper variations of those keys [there is no AltGr like in Windows.]


For those who do have a menu merchandise that seems twice within the menus, every with a distinct function, then you definitely do need to direct your key command to the proper one, utilizing this syntax
menu->submenu->merchandise
This could truly occur in equivalent to Mail, the place your Mailbox names seem on the backside of many various hierarchies, relying on perform. On this case, you’d use equivalent to
Message->Transfer to->Inbox->AccountName


Are you able to add only one single letter as a set off?
Sure…and no.
This one is difficult and has modified over time. It additionally wants your set off to be ignored when you’re in textual content areas, which limits performance considerably.

If in case you have an prolonged keyboard, then the keys in your numpad can be used as single triggers. Utilizing our Export Bookmarks… instance – right here it’s with simply the one character 1 from the numpad used as our set off.

enter image description here

Numpad keys are completely different from these above qwerty. The Mac is aware of which is which & handles then as separate entities – nonetheless you can’t inform by trying on the menu or preferences which is which. You simply need to know that is what you set it to.

If you’re on any macOS earlier than Ventura, you can even add a single key command by coming into it as
Fn letter/quantity
This may then simply register as that single key. For example, Fn A offers simply A as right here…

enter image description here

All issues thought-about, although, I would not advocate utilizing single keys as triggers – there’s simply an excessive amount of room for error.


For our odd exception – the Preview Signature that does not have a menu title to motion – let me refer you to user3439894‘s wonderful reply on Preview – add Signature by key command. Discover Menu title That is fairly complicated, and much an excessive amount of so as to add right here, nevertheless it does work very effectively.


Belongings you can not add key instructions to
Contextual menus – these on proper click on.
If there isn’t any corresponding merchandise in an precise menu, this can’t be accomplished.

‘Sensible’ menu gadgets – people who do exist within the common menu, however change relying on context. The one choice for this is able to be so as to add the identical command to each single attainable variation of that menu’s wording. As typically that would come with the file or merchandise at the moment chosen, contemplate this someplace on a scale of ‘unlikely’ to ‘inconceivable’, relying on complexity.


There are strategies by which the skilled hacker can change menu gadgets by manually modifying the related .plist file for an app, however I contemplate {that a} bridge too far for this specific QA.
If you wish to examine for your self, Safari’s .plist file is at ~/Library/Preferences/com.apple.Safari.plist. It solely shows non-default key instructions.

<dict>
    <key>Export Bookmarks…</key>
    <string>@~$e</string>
</dict>

If anybody finds any outliers, odd circumstances, or issues that seem to plain ‘not work as meant’, please put up a brand new query & hyperlink again to this one for reference.

Latest news
Related news

LEAVE A REPLY

Please enter your comment!
Please enter your name here