Add 'g:airline_solarized_dark_inactive_background' option for solarized.vim

Increases contrast to make it easier to distinguish between active and
inactive buffers.
This commit is contained in:
Yukun Lin 2019-08-10 19:54:05 +09:00
parent b851658442
commit 7f81f102ab
2 changed files with 8 additions and 1 deletions

View File

@ -7,6 +7,7 @@ function! airline#themes#solarized#refresh()
let s:background = get(g:, 'airline_solarized_bg', &background) let s:background = get(g:, 'airline_solarized_bg', &background)
let s:ansi_colors = get(g:, 'solarized_termcolors', 16) != 256 && &t_Co >= 16 ? 1 : 0 let s:ansi_colors = get(g:, 'solarized_termcolors', 16) != 256 && &t_Co >= 16 ? 1 : 0
let s:use_green = get(g:, 'airline_solarized_normal_green', 0) let s:use_green = get(g:, 'airline_solarized_normal_green', 0)
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_text = get(g:, 'airline_solarized_dark_text', 0)
let s:dark_inactive_border = get(g:, 'airline_solarized_dark_inactive_border', 0) let s:dark_inactive_border = get(g:, 'airline_solarized_dark_inactive_border', 0)
let s:tty = &t_Co == 8 let s:tty = &t_Co == 8
@ -198,7 +199,7 @@ function! airline#themes#solarized#refresh()
let g:airline#themes#solarized#palette.tabline = {} let g:airline#themes#solarized#palette.tabline = {}
let g:airline#themes#solarized#palette.tabline.airline_tab = [ let g:airline#themes#solarized#palette.tabline.airline_tab = [
\ s:I2[0].g, s:I2[1].g, s:I2[0].t, s:I2[1].t, s:I2[2]] \ s:I2[0].g, s:I2[1].g, s:I2[0].t, (s:dark_inactive_tab ? s:I3[0].t : s:I2[1].t), s:I2[2]]
let g:airline#themes#solarized#palette.tabline.airline_tabtype = [ let g:airline#themes#solarized#palette.tabline.airline_tabtype = [
\ s:N2[0].g, s:N2[1].g, s:N2[0].t, s:N2[1].t, s:N2[2]] \ s:N2[0].g, s:N2[1].g, s:N2[0].t, s:N2[1].t, s:N2[2]]

View File

@ -243,6 +243,12 @@ be shown in a nice orange. >
Turns the outer-most section of the statusline Solarized green, making it Turns the outer-most section of the statusline Solarized green, making it
look more like classic powerline in normal mode. To enable it: > look more like classic powerline in normal mode. To enable it: >
let g:airline_solarized_normal_green = 1 let g:airline_solarized_normal_green = 1
<
*airline_solarized_dark_inactive_background*
For buffer(s) in the tabline that are displayed in an inactive window pane,
use a darker background for the buffer display in the tabline. To enable it: >
let g:airline_solarized_dark_inactive_background = 1
< <
*g:airline_solarized_dark_text* *g:airline_solarized_dark_text*