Easy typing for non-english keyboards vim users [c

2019-03-25 09:38发布

In English or US keyboards keys like \, /, [ and ] are very easily typed with only one key stroke. Usually is not the same for non-english keyboards.

Is there a way to achieve the same easiness of typing for these type of keyboards?
If it is a matter of mapping keys can you please put clear instructions to do it? (Spanish layout example is welcome)

EDIT: Examples by distinct languages are very welcome!

2条回答
三岁会撩人
2楼-- · 2019-03-25 09:54

I personally just use the US keyboard whenever I'm programming cause I need most of these special keys as characters anyways. You could use different keymappings, but I personally don't think this is such a good solution - if you ever have to work on another machine you won't be able to use vim at all. If you need to type spanish characters you can just switch your keyboard layout back when typing.

查看更多
对你真心纯属浪费
3楼-- · 2019-03-25 10:13

I've suggested something already in the comments. Now, as far as simple mappings go, for normal mode you can always do the simple remapping of main keys.

nnoremap : >>
nnoremap ; >>

for example, for indent (I'm on Croatian keyboard layout here ... where the < and > characters are, I have ; and : ... I'm sure you understand the example). You can analogly remap all your local characters with parenthesis, brackets or any other essential characters.

查看更多
登录 后发表回答