diff --git a/autoload/airline/themes/solarized.vim b/autoload/airline/themes/solarized.vim index caf1196..4f47265 100644 --- a/autoload/airline/themes/solarized.vim +++ b/autoload/airline/themes/solarized.vim @@ -10,6 +10,7 @@ function! airline#themes#solarized#refresh() let s:dark_inactive_tab = get(g:, 'airline_solarized_dark_inactive_background', 0) let s:dark_text = get(g:, 'airline_solarized_dark_text', 0) let s:dark_inactive_border = get(g:, 'airline_solarized_dark_inactive_border', 0) + let s:enable_command_color = get(g:, 'airline_solarized_enable_command_color', 0) let s:tty = &t_Co == 8 """""""""""""""""""""""""""""""""""""""""""""""" @@ -101,6 +102,13 @@ function! airline#themes#solarized#refresh() let s:RM = s:NM let s:RF = s:NF + " Command mode + let s:C1 = [s:N1[0], s:violet, ''] + let s:C2 = s:N2 + let s:C3 = s:N3 + let s:CF = s:NF + let s:CM = s:NM + " Inactive, according to VertSplit in solarized " (bg dark: base00; bg light: base0) if s:background == 'dark' @@ -196,6 +204,23 @@ function! airline#themes#solarized#refresh() let g:airline#themes#solarized#palette.replace_modified.airline_warning = \ g:airline#themes#solarized#palette.normal.airline_warning + let g:airline#themes#solarized#palette.replace_modified.airline_warning = + \ g:airline#themes#solarized#palette.normal.airline_warning + + if s:enable_command_color + let g:airline#themes#solarized#palette.commandline = airline#themes#generate_color_map( + \ [s:C1[0].g, s:C1[1].g, s:C1[0].t, s:C1[1].t, s:C1[2]], + \ [s:C2[0].g, s:C2[1].g, s:C2[0].t, s:C2[1].t, s:C2[2]], + \ [s:C3[0].g, s:C3[1].g, s:C3[0].t, s:C3[1].t, s:C3[2]]) + + let g:airline#themes#solarized#palette.commandline.airline_warning = + \ g:airline#themes#solarized#palette.normal.airline_warning + + let g:airline#themes#solarized#palette.commandline_modified = { + \ 'airline_c': [s:RM[0].g, s:RM[1].g, + \ s:RM[0].t, s:RM[1].t, s:RM[2]]} + endif + let g:airline#themes#solarized#palette.tabline = {} let g:airline#themes#solarized#palette.tabline.airline_tab = [ diff --git a/doc/airline-themes.txt b/doc/airline-themes.txt index ccd1bb3..acd3059 100644 --- a/doc/airline-themes.txt +++ b/doc/airline-themes.txt @@ -262,6 +262,11 @@ To enable it: > Changes inactive window panes to have a dark bottom border instead of light by default. To enable it: > let g:airline_solarized_dark_inactive_border = 1 +< + *g:airline_solarized_enable_command_color* + +In command mode, set the status line to its own color (violet). To enable it: > + let airline_solarized_enable_command_color = 1 < *g:solarized_base16*