mirror of
https://github.com/amix/vimrc
synced 2025-06-16 09:35:01 +08:00
Updated plugins
This commit is contained in:
@ -488,8 +488,18 @@ fun! snipMate#WordBelowCursor() abort
|
||||
endf
|
||||
|
||||
fun! snipMate#GetSnippetsForWordBelowCursorForComplete(word) abort
|
||||
let snippets = map(snipMate#GetSnippetsForWordBelowCursor(a:word, 0), 'v:val[0]')
|
||||
return filter(snippets, 'v:val =~# "\\V\\^' . escape(a:word, '"\') . '"')
|
||||
let matches = snipMate#GetSnippetsForWordBelowCursor(a:word, 0)
|
||||
let snippets = []
|
||||
for [trigger, dict] in matches
|
||||
if get(g:snipMate, 'description_in_completion', 0)
|
||||
call extend(snippets, map(keys(dict),
|
||||
\ '{ "word" : trigger, "menu" : v:val, "dup" : 1 }'))
|
||||
else
|
||||
call add(snippets, { "word" : trigger })
|
||||
endif
|
||||
endfor
|
||||
return filter(snippets,
|
||||
\ 'v:val.word =~# "\\V\\^' . escape(a:word, '"\') . '"')
|
||||
endf
|
||||
|
||||
fun! snipMate#CanBeTriggered() abort
|
||||
|
@ -160,6 +160,12 @@ g:snipMate.override
|
||||
maps and other settings work. Note: Load order
|
||||
is determined by 'runtimepath'.
|
||||
|
||||
g:snipMate.description_in_completion
|
||||
If set to 1 (default is 0), snippet
|
||||
descriptions will be included in the popup
|
||||
menu used for snippet completion, like with
|
||||
<Plug>snipMateShow.
|
||||
|
||||
g:snipMate['no_match_completion_feedkeys_chars']
|
||||
A string inserted when no match for a trigger
|
||||
is found. By default a tab is inserted
|
||||
|
Reference in New Issue
Block a user