[PATCH 2/3] gitk: do not set fg/bg color scheme for themed Tk
- From
- Christoph Sommer via GitGitGadget <gitgitgadget@gmail.com>
- Date
- Apr 28, 2025, 15:56 UTC
- Message-ID
- <abe92305dcca8ebece332454004b6611ce2efd5a.1745855773.git.gitgitgadget@gmail.com>
- In-Reply-To
- <pull.1909.git.1745855773.gitgitgadget@gmail.com>
From: Christoph Sommer <sommer@cms-labs.org>
Ignore the uicolor preference not just for win32, but also whenever themed Tk is used. On themed Tk it was frequently only changing the background of only a few select widgets rather than everything - and the default uicolor was frequently not the background color that themed Tk used for its widgets, resulting in a messy looking UI (mostly light gray, with random widgets surrounded by darker gray borders)
Signed-off-by: Christoph Sommer <sommer@cms-labs.org> --- gitk-git/gitk | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/gitk-git/gitk b/gitk-git/gitk index 8cb17f39d41..da7507af360 100755 --- a/gitk-git/gitk +++ b/gitk-git/gitk @@ -11991,6 +11991,12 @@ proc setselbg {c} { # radiobuttons look bad. This chooses white for selectColor if the # background color is light, or black if it is dark. proc setui {c} { + global use_ttk + + if {$use_ttk} { + return + } + if {[tk windowingsystem] eq "win32"} { return } set bg [winfo rgb . $c] set selc black
-- gitgitgadget