diff --git a/plugin/airline.vim b/plugin/airline.vim index 2ec5eba..8b9fbc0 100644 --- a/plugin/airline.vim +++ b/plugin/airline.vim @@ -19,9 +19,9 @@ let g:airline_theme = 'default' set laststatus=2 -let g:airline_colors_normal = g:airline#themes#{g:airline_theme}#normal -let g:airline_colors_insert = g:airline#themes#{g:airline_theme}#insert -let g:airline_colors_normal = g:airline#themes#{g:airline_theme}#normal +let s:airline_colors_normal = g:airline#themes#{g:airline_theme}#normal +let s:airline_colors_insert = g:airline#themes#{g:airline_theme}#insert +let s:airline_colors_normal = g:airline#themes#{g:airline_theme}#normal function! s:highlight(colors) let cmd = printf('hi %s %s %s %s %s %s %s', @@ -38,27 +38,27 @@ endfunction function! AirlineModePrefix() let l:mode = mode() - call highlight(g:airline_colors_normal.statusline) - call highlight(g:airline_colors_normal.statusline_nc) - call highlight(g:airline_colors_normal.inactive) - call highlight(g:airline_colors_normal.mode) - call highlight(g:airline_colors_normal.mode_seperator) - call highlight(g:airline_colors_normal.info) - call highlight(g:airline_colors_normal.info_seperator) - call highlight(g:airline_colors_normal.file) + call highlight(s:airline_colors_normal.statusline) + call highlight(s:airline_colors_normal.statusline_nc) + call highlight(s:airline_colors_normal.inactive) + call highlight(s:airline_colors_normal.mode) + call highlight(s:airline_colors_normal.mode_seperator) + call highlight(s:airline_colors_normal.info) + call highlight(s:airline_colors_normal.info_seperator) + call highlight(s:airline_colors_normal.file) if l:mode ==# "i" || l:mode ==# "R" - call highlight(g:airline_colors_insert.statusline) - call highlight(g:airline_colors_insert.mode) - call highlight(g:airline_colors_insert.mode_seperator) - call highlight(g:airline_colors_insert.info) - call highlight(g:airline_colors_insert.info_seperator) + call highlight(s:airline_colors_insert.statusline) + call highlight(s:airline_colors_insert.mode) + call highlight(s:airline_colors_insert.mode_seperator) + call highlight(s:airline_colors_insert.info) + call highlight(s:airline_colors_insert.info_seperator) elseif l:mode ==? "v" || l:mode ==# "" - call highlight(g:airline_colors_visual.statusline) - call highlight(g:airline_colors_visual.mode) - call highlight(g:airline_colors_visual.mode_seperator) - call highlight(g:airline_colors_visual.info) - call highlight(g:airline_colors_visual.info_seperator) + call highlight(s:airline_colors_visual.statusline) + call highlight(s:airline_colors_visual.mode) + call highlight(s:airline_colors_visual.mode_seperator) + call highlight(s:airline_colors_visual.info) + call highlight(s:airline_colors_visual.info_seperator) endif if l:mode ==# "n"