mirror of
https://github.com/vim-airline/vim-airline-themes.git
synced 2024-12-12 05:22:12 +08:00
Allow flag configuration of tagbar statusline string
This commit is contained in:
parent
f57b65d3b8
commit
e967d09bf3
|
@ -1,6 +1,8 @@
|
||||||
" MIT License. Copyright (c) 2013 Bailey Ling.
|
" MIT License. Copyright (c) 2013 Bailey Ling.
|
||||||
" vim: et ts=2 sts=2 sw=2
|
" vim: et ts=2 sts=2 sw=2
|
||||||
|
|
||||||
|
let s:flags = get(g:, 'airline#extensions#tagbar#flags', '')
|
||||||
|
|
||||||
" Arguments: current, sort, fname
|
" Arguments: current, sort, fname
|
||||||
function! airline#extensions#tagbar#get_status(...)
|
function! airline#extensions#tagbar#get_status(...)
|
||||||
let builder = airline#builder#new({ 'active': a:1 })
|
let builder = airline#builder#new({ 'active': a:1 })
|
||||||
|
@ -18,7 +20,7 @@ endfunction
|
||||||
|
|
||||||
function! airline#extensions#tagbar#currenttag()
|
function! airline#extensions#tagbar#currenttag()
|
||||||
if get(w:, 'airline_active', 0)
|
if get(w:, 'airline_active', 0)
|
||||||
return tagbar#currenttag('%s', '')
|
return tagbar#currenttag('%s', '', s:flags)
|
||||||
endif
|
endif
|
||||||
return ''
|
return ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
|
@ -236,6 +236,9 @@ tagbar <https://github.com/majutsushi/>
|
||||||
* enable/disable tagbar integration >
|
* enable/disable tagbar integration >
|
||||||
let g:airline#extensions#tagbar#enabled = 1
|
let g:airline#extensions#tagbar#enabled = 1
|
||||||
<
|
<
|
||||||
|
* change how tags are displayed (:help tagbar-statusline) >
|
||||||
|
let g:airline#extensions#tagbar#flags = 'f'
|
||||||
|
<
|
||||||
------------------------------------- *airline-csv*
|
------------------------------------- *airline-csv*
|
||||||
csv.vim <https://github.com/chrisbra/csv.vim>
|
csv.vim <https://github.com/chrisbra/csv.vim>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user