git-gui: improve dark mode support
authorSerg Tereshchenko <serg.partizan@gmail.com>
Sat, 26 Sep 2020 14:54:43 +0000 (17:54 +0300)
committerPratyush Yadav <me@yadavpratyush.com>
Wed, 7 Oct 2020 11:14:24 +0000 (16:44 +0530)
commitc02efc13638447f9af0be6cb158a6c1a8dd4c727
tree996d932e826b3b929f9a1054fc629d3fbeccf653
parent95bfc6cdb697b971ffd7766f353d9bcf7bad9f6f
git-gui: improve dark mode support

The colors of some ttext widgets are hard-coded. These hard-coded colors
are okay with a light theme but with a dark theme some widgets are dark
colored and the hard-coded ones are still light. This defeats the
purpose of applying the theme and makes the UI look very awkward.

Remove the hard-coded colors in ttext calls and use colors from the
theme for those widgets via Text.Background and Text.Foreground from the
option database.

Similarly, the highlighting for the currently selected file(s) in the
"Staged Files" and "Unstaged Files" sections is also hard-coded. Pull
the colors for that from the current theme to make sure it is in line

Signed-off-by: Serg Tereshchenko <serg.partizan@gmail.com>
Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
git-gui.sh
lib/themed.tcl