diff --git a/autoload/airline.vim b/autoload/airline.vim index 5edbbcd..9e6b3a3 100644 --- a/autoload/airline.vim +++ b/autoload/airline.vim @@ -21,8 +21,8 @@ function! airline#exec_highlight(group, colors) endfunction function! airline#reload_highlight() - call airline#highlight(['inactive']) - call airline#highlight(['normal']) + call s:highlight(['inactive']) + call s:highlight(['normal']) call airline#extensions#load_theme() endfunction @@ -32,10 +32,10 @@ function! airline#load_theme(name) let w:airline_lastmode = '' call airline#update_statusline() call airline#reload_highlight() - call airline#update_highlight() + call airline#check_mode() endfunction -function! airline#highlight(modes) +function! s:highlight(modes) " draw the base mode, followed by any overrides let mapped = map(a:modes, 'v:val == a:modes[0] ? v:val : a:modes[0]."_".v:val') for mode in mapped @@ -108,7 +108,7 @@ function! airline#update_statusline() call setwinvar(winnr(), '&statusline', airline#get_statusline(winnr(), 1)) endfunction -function! airline#update_highlight() +function! airline#check_mode() if get(w:, 'airline_active', 1) let l:m = mode() if l:m ==# "i" @@ -131,7 +131,7 @@ function! airline#update_highlight() let mode_string = join(l:mode) if get(w:, 'airline_lastmode', '') != mode_string - call airline#highlight(l:mode) + call s:highlight(l:mode) let w:airline_lastmode = mode_string endif return '' diff --git a/autoload/airline/builder.vim b/autoload/airline/builder.vim index 89f4002..d461d3c 100644 --- a/autoload/airline/builder.vim +++ b/autoload/airline/builder.vim @@ -29,7 +29,7 @@ function! airline#builder#new(active) endfunction function! builder.build() - let line = '%{airline#update_highlight()}' + let line = '%{airline#check_mode()}' let side = 0 let prev_group = '' let separator_groups = [] diff --git a/autoload/airline/extensions/bufferline.vim b/autoload/airline/extensions/bufferline.vim index 9a863e1..c95cdf3 100644 --- a/autoload/airline/extensions/bufferline.vim +++ b/autoload/airline/extensions/bufferline.vim @@ -18,7 +18,7 @@ endfunction function! airline#extensions#bufferline#init(ext) highlight AlBl_active gui=bold cterm=bold term=bold - highlight link AlBl_inactive Al6 + highlight link AlBl_inactive airline_c let g:bufferline_inactive_highlight = 'AlBl_inactive' let g:bufferline_active_highlight = 'AlBl_active' let g:bufferline_active_buffer_left = '' diff --git a/autoload/airline/extensions/csv.vim b/autoload/airline/extensions/csv.vim index c1de708..b0402a0 100644 --- a/autoload/airline/extensions/csv.vim +++ b/autoload/airline/extensions/csv.vim @@ -5,7 +5,7 @@ if !exists('g:airline#extensions#csv#column_display') let g:airline#extensions#csv#column_display = 'Number' endif -function! airline#extensions#csv#get_statusline() +function! airline#extensions#csv#get_column() if exists('*CSV_WCol') if g:airline#extensions#csv#column_display ==# 'Name' return '['.CSV_WCol('Name').CSV_WCol().']' @@ -23,7 +23,7 @@ function! airline#extensions#csv#apply() endif let w:airline_section_gutter = \ g:airline_left_alt_sep - \ .' %{airline#extensions#csv#get_statusline()}' + \ .' %{airline#extensions#csv#get_column()}' \ .w:airline_section_gutter endif endfunction diff --git a/plugin/airline.vim b/plugin/airline.vim index b514d2b..6b5965c 100644 --- a/plugin/airline.vim +++ b/plugin/airline.vim @@ -46,7 +46,7 @@ call s:check_defined('g:airline_mode_map', { \ 'R' : 'REPLACE', \ 'v' : 'VISUAL', \ 'V' : 'V-LINE', - \ 'c' : 'CMD ', + \ 'c' : 'COMMAND', \ '' : 'V-BLOCK', \ 's' : 'SELECT', \ 'S' : 'S-LINE',