mirror of
https://github.com/vim-airline/vim-airline.git
synced 2025-12-06 20:24:27 +08:00
@@ -22,6 +22,9 @@ function! s:get_section(winnr, key, ...)
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
let spc = g:airline_symbols.space
|
let spc = g:airline_symbols.space
|
||||||
|
if !exists('g:airline_section_{a:key}')
|
||||||
|
return ''
|
||||||
|
endif
|
||||||
let text = airline#util#getwinvar(a:winnr, 'airline_section_'.a:key, g:airline_section_{a:key})
|
let text = airline#util#getwinvar(a:winnr, 'airline_section_'.a:key, g:airline_section_{a:key})
|
||||||
let [prefix, suffix] = [get(a:000, 0, '%('.spc), get(a:000, 1, spc.'%)')]
|
let [prefix, suffix] = [get(a:000, 0, '%('.spc), get(a:000, 1, spc.'%)')]
|
||||||
return empty(text) ? '' : prefix.text.suffix
|
return empty(text) ? '' : prefix.text.suffix
|
||||||
|
|||||||
Reference in New Issue
Block a user