FYI for Lion users who use IdeaVIM

If you have upgraded to Lion and you also use the IdeaVIM plugin you may be annoyed by Apple turning of key repeating (hold down a key and it repeats). Wierd! Anyway, this is a problem if you use h,j,k,l for navigation with IdeaVIM and want to move by holding down those keys.

You cannot turn off this odd decision via System Preferences, however, there is a defaults write you can use, from Terminal:


defaults write -g ApplePressAndHoldEnabled -bool false


It looks like you have to reboot before it takes effect. Although you may want to try just restarting IntelliJ and see if that works before going for the reboot (I just went for a reboot and all is well now).

0
19 comments
Avatar
Permanently deleted user

Worked great -- didn't even have to reboot!

0
Avatar
Permanently deleted user

Hello Michael,

Thanks a lot for the posting this workaround here :)

Regards,
Oleg

0
Avatar
Permanently deleted user

Nothing weird about it. The repeat is turned off on Lion because of the new feature that shows alternative accented characters when you hold down a key, e.g., è, é, etc. Be aware that turning repeat back on kills that functionality.

1
Avatar
Permanently deleted user

It is a wierd change for people that depend on the key repeat functionality and have absolutely never had to type an accented character.

0
Avatar
Permanently deleted user

Better solution: you can enable key repeat per-application, so that you can still use it in other apps (if you want to do so). For the Community Edition of IntelliJ, at least, you'd do:

defaults write com.jetbrains.intellij.ce ApplePressAndHoldEnabled -bool false

Then just restart IntelliJ and you're golden.

0

By the way, I tried that on the ultimate edution with .ue and .iu instead of .ce, but it didn't work.  The global one did, though.  Thanks!

0
Avatar
Permanently deleted user

If anyone besides me is using IdeaVIM with AppCode, the correct line is:

defaults write com.jetbrains.AppCode ApplePressAndHoldEnabled -bool false

0

And for PhpStorm correct command is:

$ defaults write com.jetbrains.PhpStorm ApplePressAndHoldEnabled -bool false
0
Avatar
Permanently deleted user

Nice job!Thank you

0
Avatar
Permanently deleted user

The correct line for Ultimate Edition is defaults write com.jetbrains.intellij ApplePressAndHoldEnabled -bool false

0
Avatar
Permanently deleted user

Thank you so much for this! Also, for those who use PyCharm:

defaults write com.jetbrains.PyCharm ApplePressAndHoldEnabled -bool false

No reboot required for me, just had to restart PyCharm.

0
Avatar
Permanently deleted user

It seems like this could be made the default behavior when installing the IdeaVIM plugin (or make it a preference).

Thanks for posting the solution!

0
Avatar
Permanently deleted user

This option is an operating system level preference, not an application level preference.

0
Avatar
Permanently deleted user

Thanks for this it works like a charm.

Cheers

0

thanks for posting this, I was really struggling with the native setup

0
Avatar
Permanently deleted user

I'd prefer not to turn off the system default for all apps, so I tried the approach suggested for app specific changes - with no luck.

defaults write com.jetbrains.RubyMine ApplePressAndHoldEnabled -bool false

Has anybody had any luck fixing the key repeat problem for RubyMine?

0
Avatar
Permanently deleted user

For Android Studio, it's:

defaults write com.google.android.studio ApplePressAndHoldEnabled -bool false

0
Avatar
Permanently deleted user

What is the command for RubyMine?

0

For WebStrom, it's:

 

defaults write com.jetbrains.WebStorm ApplePressAndHoldEnabled -bool false

0

Please sign in to leave a comment.