Sometimes I change input source (keyboard language) and my number buttons get mapped to rarely used UTF-8 symbols, e.g. 1
gets changed to ą
, 2
to č
, 3
to ę
, etc.
I have managed to map them in normal mode to numbers by using these mappings:
map ą 1
map č 2
map ę 3
map ė 4
map į 5
map š 6
map ų 7
map ū 8
map „ 9
map “ 0
However these mappings don't work in command-line mode (after pressing :
) - original symbols are used. Is there a way to tell VIM that when I enter ą
in command-line mode I mean 1?
:help 'langmap'
, to handle this in normal mode without having 10 separate mappings. Try:set langmap=ą1,č2,ę3,ė4,į5,š6,ų7,ū8,„9,“0
– Rich Feb 25 at 13:31