delta icon indicating copy to clipboard operation
delta copied to clipboard

Default dark theme: contrast is too low for comment in addition line

Open OliverJAsh opened this issue 4 years ago • 7 comments

Hi, thanks for sharing this amazing tool.

I noticed that when we have a comment that was added, the contrast of grey text on the green background is extremely low which makes it hard to read. Perhaps we could increase the brightness of the text, or increase the darkness of the green background?

image

OliverJAsh avatar Aug 15 '20 21:08 OliverJAsh

Hi @OliverJAsh, thanks!

I am definitely open to suggestions for how to improve the defaults, especially for dark backgrounds, for which I have always felt there is room for improvement. Have you tried experimenting with different syntax-highlighting themes (affecting foreground colours from syntax highlighting), and experimenting with the style options to adjust the background colours? The grey colour in your screenshot derives from the syntax highlighting theme, and the green background colour is plus-style.

dandavison avatar Aug 17 '20 15:08 dandavison

To me, it's not so much the addition line as it is the emphasized part of an addition line. Just about every built-in theme is (nearly) unreadable in that situation. This is with comment lines specifically (Rust if that matters).

jhpratt avatar Sep 22 '20 07:09 jhpratt

Hi @jhpratt, have you tried using plus-emph-style to select the color you want for emphasized parts of added lines? Similarly, @OliverJAsh, you can select the background color using plus-style.

I'm happy to accept suggestions for different defaults!

dandavison avatar Sep 22 '20 14:09 dandavison

I didn't spend too long playing around with it, but I couldn't find anything that was green yet both distinguishable from the non-emphasized text and had sufficient contrast.

jhpratt avatar Sep 22 '20 23:09 jhpratt

I got a slightly better contrast with:

plus-style = "syntax \"#184b54\""
minus-style = "syntax \"#642f33\""

image

eliezio avatar Dec 16 '21 12:12 eliezio

IMO the problem is the syntax color, not the backgorund color. Looking through --show-syntax-themes, Coldark-Dark and zenburn are somewhat better for making comments visible.

durka avatar Apr 29 '22 19:04 durka

Thanks for putting me in the right direction @durka

Theme Coldark-Dark works much better. If possible I would use this as the default.

buckleyGI avatar Feb 26 '24 15:02 buckleyGI