Fixes #119, allow disabling <C-h> mapping.
This commit is contained in:
parent
0c30ba85f0
commit
65a7237b2b
@ -24,6 +24,11 @@ if !exists('g:AutoPairsMapBS')
|
|||||||
let g:AutoPairsMapBS = 1
|
let g:AutoPairsMapBS = 1
|
||||||
end
|
end
|
||||||
|
|
||||||
|
" Map <C-h> as the same BS
|
||||||
|
if !exists('g:AutoPairsMapCh')
|
||||||
|
let g:AutoPairsMapCh = 1
|
||||||
|
end
|
||||||
|
|
||||||
if !exists('g:AutoPairsMapCR')
|
if !exists('g:AutoPairsMapCR')
|
||||||
let g:AutoPairsMapCR = 1
|
let g:AutoPairsMapCR = 1
|
||||||
end
|
end
|
||||||
@ -437,9 +442,12 @@ function! AutoPairsInit()
|
|||||||
if g:AutoPairsMapBS
|
if g:AutoPairsMapBS
|
||||||
" Use <C-R> instead of <expr> for issue #14 sometimes press BS output strange words
|
" Use <C-R> instead of <expr> for issue #14 sometimes press BS output strange words
|
||||||
execute 'inoremap <buffer> <silent> <BS> <C-R>=AutoPairsDelete()<CR>'
|
execute 'inoremap <buffer> <silent> <BS> <C-R>=AutoPairsDelete()<CR>'
|
||||||
execute 'inoremap <buffer> <silent> <C-H> <C-R>=AutoPairsDelete()<CR>'
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if g:AutoPairsMapCh
|
||||||
|
execute 'inoremap <buffer> <silent> <C-h> <C-R>=AutoPairsDelete()<CR>'
|
||||||
|
endif
|
||||||
|
|
||||||
if g:AutoPairsMapSpace
|
if g:AutoPairsMapSpace
|
||||||
" Try to respect abbreviations on a <SPACE>
|
" Try to respect abbreviations on a <SPACE>
|
||||||
let do_abbrev = ""
|
let do_abbrev = ""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user