The ‘git-gutter’ and ‘git-gutter-fr’ packages default to drawing bitmaps for the indicators they display (e.g. bitmap of a plus sign for added lines). In Doom Emacs, these bitmaps are replaced with contiguous lines which may look nicer, but require a change to the foreground of the relevant faces to yield the desired color combinations.
Since this is Doom-specific, we urge users to apply changes in their local setup. Below is some sample code, based on what we cover at length elsewhere in this manual:
Face specs at scale using the themes’ palette.
(defun my-modus-themes-custom-faces () (modus-themes-with-colors (custom-set-faces ;; Replace green with blue if you use `modus-themes-deuteranopia'. `(git-gutter-fr:added ((,class :foreground ,green-fringe-bg))) `(git-gutter-fr:deleted ((,class :foreground ,red-fringe-bg))) `(git-gutter-fr:modified ((,class :foreground ,yellow-fringe-bg)))))) (add-hook 'modus-themes-after-load-theme-hook #'my-modus-themes-custom-faces)
As always, re-load the theme for changes to take effect.
If the above does not work, try this instead:
(after! modus-themes (modus-themes-with-colors (custom-set-faces ;; Replace green with blue if you use `modus-themes-deuteranopia'. `(git-gutter-fr:added ((,class :foreground ,green-fringe-bg))) `(git-gutter-fr:deleted ((,class :foreground ,red-fringe-bg))) `(git-gutter-fr:modified ((,class :foreground ,yellow-fringe-bg))))))
Replace green-fringe-bg
with blue-fringe-bg
if you want to optimize
for red-green color deficiency.