3

What are all of the ways a keyboard shortcut could be bound in Safari?

I am aware of the following:

  • The app’s own standard shortcuts
  • System Preferences > Keyboard > Shortcuts >
    • App Shortcuts >
      • All Applications
      • Safari
    • Services
  • Safari Extensions
  • KeyBindings.dict
  • 3rd party utility applications
    • Alfred
    • FastScripts
    • Keyboard Maestro

Are there other obvious paths I could be missing? Are there ways of figuring out how a specific keybinding is being handled?

For context, I created a utility shortcut for myself to send the current Safari tab to Chrome by pressing ^c. I did this a few years ago with an Alfred Workflow, with a Hotkey trigger scoped to com.apple.safari and a simple AppleScript to get and reopen the front tab's URL.

Great. However, changing the keybinding of this workflow today I discovered that it also seems to be captured by something else I set up at some point (and bound to basically the same action). With the Alfred workflow disabled, its keybinding changed, or Alfred itself quit and not running, I have verified that the Alfred version does not run, but something else is triggering the page to open in Chrome.

I do not have FastScripts or Keyboard Maestro on this Mac. I do not see any bindings for this key in the System Preferences. I do not have /Library/KeyBindings/ or ~/Library/KeyBindings/ folders on this Mac. I don’t see any bindings in any of the areas of the Keyboard > Shortcuts preference pane. There don’t seem to be any plausibly-related Safari Extensions installed.

Shortcut Detective can detect when Alfred catches a keybinding from Safari, but sees nothing when the still-caught ^c is handled by whatever else is grabbing it.

I can’t for the life of me figure out where else I managed to bind this shortcut, and therefore can’t figure out how to unbind it short of wiping my account.

2 Answers 2

2

I've run across this post on StackOverflow that addresses this. Basically, there's no central repository of all the shortcuts created because, in the end, the application isn't required to register the event with the system.

However, they did recommend an application (KeyCue from Ergonis, €19; Free Trial) that has the ability to find all of the shortcuts that are assigned to an application (i.e. Firefox). I downloaded and tested the application and it seems promising.

(Thanks to user Nimesh Neema - see comments below), you can also use CheatSheet ($0; free as in beer). Both work in the same manner with roughly the same output (KeyCue is shown below).

Holding down the ⌘ Command key for a couple of seconds brings up an overlay showing all of the keyboard shortcuts that are assigned to the "front most" App - in this case, Firefox.

enter image description here

If you're searching for a particular shortcut you'll have to go through each running app manually to find it. So, as stated in the SO answer, while not perfect, this will get you close to what you're looking for.

5
  • 1
    @jrk I remember using a similar app CheatSheet that would display all the keyboard shortcuts for the front-most app when the Command key is held. It may not display the shortcuts as comprehensively as KeyCue, but its free of cost. Thought I would share it.
    – Nimesh Neema
    Commented Apr 3, 2020 at 16:18
  • 1
    Thanks @NimeshNeema - I added that info to the answer a free app is always a good thing!
    – Allan
    Commented Apr 5, 2020 at 3:20
  • Thanks for the tip. I am familiar with and have used CheatSheet, but unfortunately these tools do not show the shortcut in question.
    – jrk
    Commented Apr 13, 2020 at 14:32
  • @jrk - see the StackOverflow link. the problem is that an app isn't required to register the event so it doesn't show up anywhere.
    – Allan
    Commented Apr 13, 2020 at 15:39
  • Unfortunately, CheatSheet is no longer supported by its developer, who recommends either the commercial KeyCue or the free KeyClu.
    – Dave Land
    Commented Nov 8, 2023 at 18:49
0

I encountered a similar issue. Something unknown was system-wide taking over a keyboard shortcut that is common in browsers and Finder (SHIFT+COMMAND+N in this instance).

No other open applications showed that they were even taking over that shortcut or even using it knowingly. So it was tricky to figure out what app was taking over the shortcut. Using the shortcut itself would do nothing, no matter which app was active in the foreground.

The best and most effective way I found for determining which application is taking over a keyboard shortcut is an app called ShortcutDetective, available freely from IrradiatedLabs.

I found it crashes quite a often, but it perfectly solved the issue of needing to find out what unidentifiable app was globally taking over a specific keyboard shortcut.

Here you can see it in action: enter image description here

In my case I was able to discover that an application that doesn't even show it uses the shortcut was taking it over. Presumably because of a bug.

Tools like CheatSheet and Keycue were of no use in figuring this out, as even if I brought the problematic app to the forefront, neither of these tools would show that it was assigning anything to the shortcut I was having issues with.

1
  • 1
    Did you actually read the question?
    – nohillside
    Commented May 21, 2023 at 5:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .