Use white foreground color when cells have dark background
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GTG |
Fix Released
|
Wishlist
|
Izidor Matušov |
Bug Description
Using the urgency color plugin (bug #906516), one may want to mark specific tasks with dark background colors. For instance, overdue or urgent tasks may be marked with a darkish red background. In this case it is better to have a white foreground color - the text is more visible. This has never been a problem so far, since GTG uses a very pale background for tags-based coloring. For urgency-based coloring I think it makes sense to use dark backgrounds.
I propose a simple modification (see patch) to the lilblarch package, so that text is rendered white dynamically depending on the background brightness. The definition of the brightness is taken from here
http://
It is such that background colors determined using tags do not exceed the threshold, thus the original behavior (black foreground) is reproduced when the plugin is disabled. In a sense, even though the modification is applied globally, it is only active when using the plugin.
Changed in gtg: | |
status: | New → Triaged |
importance: | Undecided → Wishlist |
assignee: | nobody → Izidor Matušov (izidor) |
milestone: | none → 0.3 |
Changed in gtg: | |
status: | Fix Committed → Fix Released |
I've merged your patch: https:/ /github. com/liblarch/ liblarch/ commit/ d059a79ba389a56 03cc230f0a78d15 f6683d4409
I also done a few changes: https:/ /github. com/liblarch/ liblarch/ commit/ 16d7be426c4a493 4d6a982be0d9d29 e7b13f260f
Closing as fix committed. Thanks for your contribution!