Skip to content

Commit

Permalink
diffAdded -> Added
Browse files Browse the repository at this point in the history
With the upstream changes in
vim/vim@124371c
the diffAdded group already links to Added now (which transitively maps
to DiffAdd from our colorscheme).

Instead overwrite the Added highlight group.

In the future we should reconsider if we really want diffAdded (used for
the diff filetype (e.g. opening a file.diff)) and DiffAdd (used for
actual diffing in vim) to have the same color. The latter one is
expected to have a very strong highlight (which we currently have for
both), but the former might be expected to have a slightly less
invasive/aggressive highlight, e.g. compare it with the commit linked
above.

If we ever modify this, we should make sure that the diffAdded groups
keep working (which it does right now due to transitive mapping over
Added). In that case it is probably easiest to keep vim's existing
default link from diffAdded to Added, then define Added ourself (instead
of linking to DiffAdd as we do now), and still keep defining DiffAdd
ourself.
  • Loading branch information
vimpostor committed Jul 28, 2024
1 parent 5c29db5 commit be62e53
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions colors/prism.vim
Original file line number Diff line number Diff line change
Expand Up @@ -228,9 +228,9 @@ hi! link SpecialKey Special
hi! link StatusLineTerm StatusLine
hi! link StatusLineTermNC StatusLineNC
hi! link TabLineFill TabLine
hi! link diffAdded DiffAdd
hi! link diffChanged DiffChange
hi! link diffRemoved DiffDelete
hi! link Added DiffAdd
hi! link Changed DiffChange
hi! link Removed DiffDelete

if has('nvim')
exec s:hls('FloatShadow', 'none', 'black', s:none, 'blend=80')
Expand Down

0 comments on commit be62e53

Please sign in to comment.