Recently, when I try to use Ctrl-left and Ctrl-right in Neovim, I found that they are not received by Neovim.
I thought this is a Neovim issue.
However, when I test these two shortcuts using cat in the terminal (I tried both Kitty and wezterm),
it does not work either.
I asked this question in Vim_zh telegraph group1, and someone reminded me that it may be related to macOS mapping these keys for mission control2. There are multiple similar posts on the Internet.
Here is what is working for me on macOS Monterey (version 12.5.1):
- Open
System Preferences --> Keyboard - Go to the
shortcutstab, and clickMission Controlon the left list - Under
Mission Controlmenu on the right, uncheckMove left a spaceandMove right a space.
Now these two shortcuts will be freed.
BTW, if you like to switch between different desktops, you can use three finger swipes on the touch pad. It works better than using key shortcuts.
This is a telegraph group for Chinese Vim/Nvim users, with a lot of profession devs. ↩︎
Mission control is basically multiple desktops, see also https://en.wikipedia.org/wiki/Mission_Control_(macOS) ↩︎