macOS - Remap cmd+h

Answered

On macOS 13, when I remap cmd+h to something more useful, like, for example, move left, IDEA witth both execute the command (in this case, moving the cursor left) AND hide the window. Clearly not very useful if I need to reopen the window every time I need to move my cursor left. I have already unbound anything that might minimise the window, and IDEA doesn't report a conflict when I go and bind cmd+h.

This is not a case of being unable to override a system-wide keybinding, since the exact same remapping in both VS Code and Atom works just fine.

So, my question is: how can I remap cmd+h to something else without it also hiding the window every single time? Is it just that I missed unbinding some hide command somewhere? Or do I need to do some magic scripting with karabiner-elements + hammerspoon to avoid the conflict?

2
3 comments

Bug report is welcome at https://youtrack.jetbrains.com/issues/IDEA. I didn't manage to find similar reports.

Note that remapping cursor keys will not work in all places, see https://youtrack.jetbrains.com/v2/issue/IDEA-108609 and the linked issues.

0
Avatar
Permanently deleted user

I wasn't able to get IntelliJ to override cmd+h, but I was able to remove the original hotkey. The fix was to add a *new* shortcut to hide IntelliJ, thus replacing the cmd+h one. To do that, go to System Preferences > Keyboard > Shortcuts > App Shortcuts, hit the + button, select IntelliJ, and set the Menu Title to (exactly) "Hide IntelliJ IDEA". Then, click the Keyboard Shortcut box and create a shortcut that definitely won't interfere with your workflow. I chose `cmd+shift+ctrl+0`. Hope that helps!

5

OMG, thank you.  This was driving me nuts.

0

Please sign in to leave a comment.