+ " Return current syntax group in brackets or nothing if there's none.
+ function! s:StatuslineSyntaxGroup()
+ let l:group = synIDattr(synID(line('.'), col('.'), 1), 'name')
+ if l:group != ''
+ return '[' . l:group . '] '
+ else
+ return ''
+ endif
+ endfunction
+
+ " Short function names to make 'statusline' more readable.
+ function! SBC()
+ return <SID>StatuslineBufferCount()
+ endfunction
+ function! SRF()
+ return <SID>StatuslineRelativeFilename()
+ endfunction
+ function! SSG()
+ return <SID>StatuslineSyntaxGroup()
+ endfunction
+