Skip to content

Commit

Permalink
Varying selection highlight with option (issue morhetz#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
morhetz authored and Splinter1984 committed Nov 2, 2023
1 parent 4b8da6c commit b4b7d22
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions colors/gruvbox.vim
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ if !exists('g:gruvbox_invert_signs')
let g:gruvbox_invert_signs=0
endif

if !exists('g:gruvbox_invert_selection')
let g:gruvbox_invert_selection=1
endif

if &background == 'light'
let s:gruvbox_background='light'
else
Expand Down Expand Up @@ -278,8 +282,13 @@ endif
call s:HL('NonText', 'dark2')
call s:HL('SpecialKey', 'dark2')

call s:HL('Visual', 'none', 'dark3', 'inverse')
call s:HL('VisualNOS', 'none', 'dark3', 'inverse')
if g:gruvbox_invert_selection == 0
call s:HL('Visual', 'none', 'dark2')
call s:HL('VisualNOS', 'none', 'dark2')
else
call s:HL('Visual', 'none', 'dark3', 'inverse')
call s:HL('VisualNOS', 'none', 'dark3', 'inverse')
endif

call s:HL('Search', 'dark0', 'yellow')
call s:HL('IncSearch', 'dark0', g:gruvbox_hls_cursor)
Expand Down

0 comments on commit b4b7d22

Please sign in to comment.