Improve menu
This commit is contained in:
parent
bab27f8a95
commit
7c07c4d8a2
@ -29,6 +29,7 @@ set cpo&vim
|
|||||||
let s:source = {
|
let s:source = {
|
||||||
\ 'name' : 'neosnippet',
|
\ 'name' : 'neosnippet',
|
||||||
\ 'kind' : 'keyword',
|
\ 'kind' : 'keyword',
|
||||||
|
\ 'mark' : '[nsnip]',
|
||||||
\ 'rank' : 8,
|
\ 'rank' : 8,
|
||||||
\ 'hooks' : {},
|
\ 'hooks' : {},
|
||||||
\ 'matchers' :
|
\ 'matchers' :
|
||||||
|
@ -223,8 +223,6 @@ function! neosnippet#parser#_initialize_snippet(dict, path, line, pattern, name)
|
|||||||
let a:dict.word .= '${0}'
|
let a:dict.word .= '${0}'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
let menu_prefix = '[nsnip] '
|
|
||||||
|
|
||||||
if !has_key(a:dict, 'abbr') || a:dict.abbr == ''
|
if !has_key(a:dict, 'abbr') || a:dict.abbr == ''
|
||||||
" Set default abbr.
|
" Set default abbr.
|
||||||
let abbr = substitute(a:dict.word,
|
let abbr = substitute(a:dict.word,
|
||||||
@ -239,7 +237,7 @@ function! neosnippet#parser#_initialize_snippet(dict, path, line, pattern, name)
|
|||||||
let snippet = {
|
let snippet = {
|
||||||
\ 'word' : a:dict.name, 'snip' : a:dict.word,
|
\ 'word' : a:dict.name, 'snip' : a:dict.word,
|
||||||
\ 'description' : a:dict.word,
|
\ 'description' : a:dict.word,
|
||||||
\ 'menu_template' : menu_prefix . abbr,
|
\ 'menu_template' : abbr,
|
||||||
\ 'menu_abbr' : abbr,
|
\ 'menu_abbr' : abbr,
|
||||||
\ 'options' : a:dict.options,
|
\ 'options' : a:dict.options,
|
||||||
\ 'action__path' : a:path, 'action__line' : a:line,
|
\ 'action__path' : a:path, 'action__line' : a:line,
|
||||||
|
Loading…
Reference in New Issue
Block a user