Allow "|" to be used in mappings.

This commit is contained in:
Israel Chauca Fuentes
2010-08-21 11:29:29 -05:00
parent 58d63b4e5b
commit efadb34c84
2 changed files with 30 additions and 8 deletions

View File

@@ -27,8 +27,12 @@ function! delimitMateTests#Main()
let b:delimitMate_tab2exit = 1
" Set current test options:
for str in a:list
let pair = split(str, ':')
exec "let b:delimitMate_" . pair[0] . " = " . pair[1]
"echom '1:'.str
let op = strpart(str, 0, stridx(str,':'))
"echom op
let val = strpart(str, stridx(str, ':' ) + 1)
"echom val
exec "let b:delimitMate_" . op . " = " . val
endfor
DelimitMateReload
endfunction " }}}
@@ -243,6 +247,12 @@ function! delimitMateTests#Main()
" Manual close at start of line
call Type("Manual close at start of line", "m)\<Left>\<Left>)", [')|m)'], ["autoclose:0"])
" Use | in quotes
call Type("Use <Bar> in quotes", "\<Bar>bars", ['|bars|'], ["quotes:'|'"])
" Use | in matchpairs
call Type("Use <Bar> in matchpairs", "\<Bar>bars", ['|bars|$$'], ["matchpairs:'|:$'"])
"}}}
" Show results: {{{