diff options
author | fvogel <fvogelnew1@free.fr> | 2016-10-12 19:30:58 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2016-10-12 19:30:58 (GMT) |
commit | 685b8e2972aff70596e861c3369e48067e55a112 (patch) | |
tree | 275f97c6fc6a3ef2764da393af50745092b95e9a /library/ttk/defaults.tcl | |
parent | a193632d10533d3800204b95ae54bb963f7f4e0e (diff) | |
parent | 3777c7414cf7ce927a2e71969018eab91f98815b (diff) | |
download | tk-685b8e2972aff70596e861c3369e48067e55a112.zip tk-685b8e2972aff70596e861c3369e48067e55a112.tar.gz tk-685b8e2972aff70596e861c3369e48067e55a112.tar.bz2 |
Fixed [3217462fff] - Tri-state buttons not working for non-native themes
Diffstat (limited to 'library/ttk/defaults.tcl')
-rw-r--r-- | library/ttk/defaults.tcl | 39 |
1 files changed, 27 insertions, 12 deletions
diff --git a/library/ttk/defaults.tcl b/library/ttk/defaults.tcl index 4551966..43e68d1 100644 --- a/library/ttk/defaults.tcl +++ b/library/ttk/defaults.tcl @@ -5,16 +5,19 @@ namespace eval ttk::theme::default { variable colors array set colors { - -frame "#d9d9d9" - -foreground "#000000" - -window "#ffffff" - -text "#000000" - -activebg "#ececec" - -selectbg "#4a6984" - -selectfg "#ffffff" - -darker "#c3c3c3" - -disabledfg "#a3a3a3" - -indicator "#4a6984" + -frame "#d9d9d9" + -foreground "#000000" + -window "#ffffff" + -text "#000000" + -activebg "#ececec" + -selectbg "#4a6984" + -selectfg "#ffffff" + -darker "#c3c3c3" + -disabledfg "#a3a3a3" + -indicator "#4a6984" + -disabledindicator "#a3a3a3" + -altindicator "#9fbdd8" + -disabledaltindicator "#c0c0c0" } ttk::style theme settings default { @@ -45,12 +48,24 @@ namespace eval ttk::theme::default { ttk::style configure TCheckbutton \ -indicatorcolor "#ffffff" -indicatorrelief sunken -padding 1 ttk::style map TCheckbutton -indicatorcolor \ - [list pressed $colors(-activebg) selected $colors(-indicator)] + [list pressed $colors(-activebg) \ + {!disabled alternate} $colors(-altindicator) \ + {disabled alternate} $colors(-disabledaltindicator) \ + {!disabled selected} $colors(-indicator) \ + {disabled selected} $colors(-disabledindicator)] + ttk::style map TCheckbutton -indicatorrelief \ + [list alternate raised] ttk::style configure TRadiobutton \ -indicatorcolor "#ffffff" -indicatorrelief sunken -padding 1 ttk::style map TRadiobutton -indicatorcolor \ - [list pressed $colors(-activebg) selected $colors(-indicator)] + [list pressed $colors(-activebg) \ + {!disabled alternate} $colors(-altindicator) \ + {disabled alternate} $colors(-disabledaltindicator) \ + {!disabled selected} $colors(-indicator) \ + {disabled selected} $colors(-disabledindicator)] + ttk::style map TRadiobutton -indicatorrelief \ + [list alternate raised] ttk::style configure TMenubutton \ -relief raised -padding "10 3" |