[英]map vim leader key to backspace
The vim documention on how to set the default leader key ( :h mapleader
) provides one simple example:关于如何设置默认前导键 (
:h mapleader
) 的 vim 文档提供了一个简单的例子:
:let mapleader = ","
I want to map it to backspace and tried a bunch of options, this being the first one:我想将它映射到退格键并尝试了很多选项,这是第一个:
:let mapleader="<BS>"
But nothing seemed to work.但似乎没有任何效果。
To make it work I had to use:为了使它工作,我必须使用:
:let mapleader="\<BS>"
Another option is to not override the default \\
leader key, but map backspace to it, effectively ending up with two simultaneous leader keys:另一种选择是不覆盖默认的
\\
leader 键,而是将退格键映射到它,有效地以两个同时的前导键结束:
map <BS> <Leader>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.