问题描述
我承认我不是专家 vim
用户,所以请原谅我没有提供以前的尝试!
I admit that I'm not an expert vim
user so forgive me not providing previous attempts!
我希望覆盖/重新映射基本的vi
/vim
(和gvim
)光标键"hjkl 到普通的玩家布局"wasd(w-up、a-left、s-down、d-right).此外:我知道w"、a"、s"和d"是 vim
中的重要键,所以我想出了将 hjkl 重新映射到ALT + wasd.
I wish to overwrite/remap the basic vi
/vim
(and gvim
) "cursor keys" hjkl to the ordinary "gamer layout" wasd (w-up, a-left, s-down, d-right). Moreover: I know that "w", "a", "s" and "d" are important keys in vim
so I came up with the idea to remap hjkl to ALT + wasd.
必须配置 .vimrc 吗?或者有什么插件吗?你能帮我吗?
Have to configure .vimrc? Or is there some plugin? Can you help me?
推荐答案
将你的 Alt + aswd 映射到 hjkl;在你的 .vimrc
Map your Alt + aswd to hjkl; in your .vimrc
noremap <A-a> h
noremap <A-s> j
noremap <A-w> k
noremap <A-d> l
这篇关于Vim:将“光标"键 hjkl 设置为 wasd的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!