Skip to content

Commit

Permalink
Fix invalid color map for treeview
Browse files Browse the repository at this point in the history
This resolves an issue where the a Tcl app with the dark theme applied would throw an error when selecting row in a treeview.

This doesn't affect the sv-ttk Python package as this bug was only present in main.
  • Loading branch information
rdbende authored Nov 5, 2023
1 parent ea91020 commit 37db572
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion sv_ttk/theme/dark.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,9 @@ namespace eval ttk::theme::sv_dark {
-rowheight [expr {[font metrics SunValleyBodyFont -linespace] + 3}] \
-font SunValleyBodyFont

ttk::style map Treeview -background {selected "#292929"} -foreground {selected $colors(-selfg)}
ttk::style map Treeview \
-background {selected "#292929"} \
-foreground [list selected $theme_colors(-selfg)]

ttk::style element create Treeview.field image $I(card) -border 5 -width 0 -height 0

Expand Down

0 comments on commit 37db572

Please sign in to comment.