Because I'm on a german keyboard layout {
and }
are relatively hard to type.
As a workaround especially for latex I used inoremap <C-j> {
and inoremap <C-l> }
which works great. After internalizing these I also tried to use them in all other modes via noremap <C-j> {
e.g. such that /<C-j>
would search for {
and ci<C-j>
change in curly braces, but this doesn't work.
I also tried onoremap
and lnoremap
which both failed. But it does work in normal mode i.e. <C-j>
moves a paragraph backward.
As far as I understand /
and c
should both go into "operator-pending" mode, so that map
and omap
should both work. I also couldn't find information that <C-j>
is "special" like <C-h>
, and I guess in that case imap
shouldn't work either. Am I overlooking something?
I tested this on vim 7.4 with an empty config.