Search code examples
macosvimmacvim

Ctrl-U doesn't work in MacVim


The shortcut Ctrl+U (in normal mode) doesn't work in my MacVim, while Ctrl+D works fine. Also Ctrl+O does nothing, while Ctrl+I works as extected. Could anyone help me please?

I'm using MacVim 7.4 and OS X 10.10.3. I'm sure it was fine a month ago, but I don't remember exactly when it went wrong. It could be Yosemite that I upgraded from Marvericks like a week ago.

In more details:

  • It's only the case at GUI(no problem in vim on a terminal)
  • Ctrl+U and Ctrl+O in other software(such as Eclipse) are fine
  • :nmap tells me there is no map for C-U or C-O(meaning default, right?)
  • When I delete .vimrc, .gvimrc, and all the plugin, I still have the same problem
  • When I press Ctrl+Shift+U, strangely enough it works(page-up)
  • Also Ctrl+Shift+O navigates back in jumplist

Thanks in advance.


Solution

  • It turned out that it's caused by the new Japanese IM which was introduced in Yosemite. The IM has a setting called "Enable Windows-like key operations" in the system preferences. I have no idea what the setting means, but disabling it solved my problem.

    Thanks.