mirror of
https://github.com/Raimondi/delimitMate.git
synced 2025-12-06 20:54:31 +08:00
Consider more characters in smart_matchpairs default value.
This commit is contained in:
@@ -107,7 +107,7 @@ function! s:init() "{{{
|
|||||||
" jump_expansion
|
" jump_expansion
|
||||||
call s:option_init("jump_expansion", 0)
|
call s:option_init("jump_expansion", 0)
|
||||||
" smart_matchpairs
|
" smart_matchpairs
|
||||||
call s:option_init("smart_matchpairs", '^\%(\w\|\!\|£\|\$\|_\)')
|
call s:option_init("smart_matchpairs", '^\%(\w\|\!\|[£$]\|[^[:punct:][:space:]]\)')
|
||||||
" smart_quotes
|
" smart_quotes
|
||||||
" XXX: backward compatibility. Ugly, should go the way of the dodo soon.
|
" XXX: backward compatibility. Ugly, should go the way of the dodo soon.
|
||||||
let quotes = escape(join(s:get('quotes_list'), ''), '\-^[]')
|
let quotes = escape(join(s:get('quotes_list'), ''), '\-^[]')
|
||||||
@@ -326,10 +326,10 @@ function! s:ExtraMappings() "{{{
|
|||||||
" If pair is empty, delete both delimiters:
|
" If pair is empty, delete both delimiters:
|
||||||
inoremap <silent> <Plug>delimitMateBS <C-R>=delimitMate#BS()<CR>
|
inoremap <silent> <Plug>delimitMateBS <C-R>=delimitMate#BS()<CR>
|
||||||
if !hasmapto('<Plug>delimitMateBS','i')
|
if !hasmapto('<Plug>delimitMateBS','i')
|
||||||
if maparg('<BS>', 'i') == ''
|
if empty(maparg('<BS>', 'i'))
|
||||||
silent! imap <unique> <buffer> <BS> <Plug>delimitMateBS
|
silent! imap <unique> <buffer> <BS> <Plug>delimitMateBS
|
||||||
endif
|
endif
|
||||||
if maparg('<C-h>', 'i') == ''
|
if empty(maparg('<C-H>', 'i'))
|
||||||
silent! imap <unique> <buffer> <C-h> <Plug>delimitMateBS
|
silent! imap <unique> <buffer> <C-h> <Plug>delimitMateBS
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
@@ -39,3 +39,13 @@ let b:delimitMate_eol_marker = ';'
|
|||||||
unlet b:delimitMate_eol_marker
|
unlet b:delimitMate_eol_marker
|
||||||
iabb def ghi
|
iabb def ghi
|
||||||
"def(" "ghi()"
|
"def(" "ghi()"
|
||||||
|
iunabb def
|
||||||
|
|
||||||
|
"abc а\<Left>(" "abc (а"
|
||||||
|
"abc ñ\<Left>(" "abc (ñ"
|
||||||
|
"abc $\<Left>(" "abc ($"
|
||||||
|
"abc £\<Left>(" "abc (£"
|
||||||
|
"abc d\<Left>(" "abc (d"
|
||||||
|
"abc \<C-V>(\<Left>(" "abc (("
|
||||||
|
"abc .\<Left>(" "abc ()."
|
||||||
|
"abc \<Left>(" "abc () "
|
||||||
|
|||||||
Reference in New Issue
Block a user