diff options
author | fvogel <fvogelnew1@free.fr> | 2018-01-07 14:55:04 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2018-01-07 14:55:04 (GMT) |
commit | 8a27524ccad82ff2c322fa889f9763a8a00c59d1 (patch) | |
tree | ffb158103a0a6149d6171b6c7ec7725f6987275c /library/ttk | |
parent | fa98eb635fd54def7bee5ffa989f704b4198f35a (diff) | |
parent | 11e2b76960b0377505fdfed92ffafaa5e65c6c4d (diff) | |
download | tk-8a27524ccad82ff2c322fa889f9763a8a00c59d1.zip tk-8a27524ccad82ff2c322fa889f9763a8a00c59d1.tar.gz tk-8a27524ccad82ff2c322fa889f9763a8a00c59d1.tar.bz2 |
Fix [882108bf05]: Incorrect style for disabled state of treeview
Diffstat (limited to 'library/ttk')
-rw-r--r-- | library/ttk/altTheme.tcl | 8 | ||||
-rw-r--r-- | library/ttk/aquaTheme.tcl | 9 | ||||
-rw-r--r-- | library/ttk/clamTheme.tcl | 8 | ||||
-rw-r--r-- | library/ttk/classicTheme.tcl | 8 | ||||
-rw-r--r-- | library/ttk/defaults.tcl | 8 | ||||
-rw-r--r-- | library/ttk/vistaTheme.tcl | 8 | ||||
-rw-r--r-- | library/ttk/winTheme.tcl | 8 | ||||
-rw-r--r-- | library/ttk/xpTheme.tcl | 10 |
8 files changed, 53 insertions, 14 deletions
diff --git a/library/ttk/altTheme.tcl b/library/ttk/altTheme.tcl index 5630e6c..6fc76f8 100644 --- a/library/ttk/altTheme.tcl +++ b/library/ttk/altTheme.tcl @@ -95,8 +95,12 @@ namespace eval ttk::theme::alt { ttk::style configure Heading -font TkHeadingFont -relief raised ttk::style configure Treeview -background $colors(-window) ttk::style map Treeview \ - -background [list selected $colors(-selectbg)] \ - -foreground [list selected $colors(-selectfg)] ; + -background [list disabled $colors(-frame)\ + {!disabled !selected} $colors(-window) \ + selected $colors(-selectbg)] \ + -foreground [list disabled $colors(-disabledfg) \ + {!disabled !selected} black \ + selected $colors(-selectfg)] ttk::style configure TScale \ -groovewidth 4 -troughrelief sunken \ diff --git a/library/ttk/aquaTheme.tcl b/library/ttk/aquaTheme.tcl index fa0fa12..d6be5a3 100644 --- a/library/ttk/aquaTheme.tcl +++ b/library/ttk/aquaTheme.tcl @@ -41,8 +41,13 @@ namespace eval ttk::theme::aqua { ttk::style configure Heading -font TkHeadingFont ttk::style configure Treeview -rowheight 18 -background White ttk::style map Treeview \ - -background {{selected background} systemHighlightSecondary - selected systemHighlight} + -background [list disabled systemDialogBackgroundInactive \ + {!disabled !selected} systemWindowBody \ + {selected background} systemHighlightSecondary \ + selected systemHighlight] \ + -foreground [list disabled systemModelessDialogInactiveText \ + {!disabled !selected} black \ + selected systemModelessDialogActiveText] # Enable animation for ttk::progressbar widget: ttk::style configure TProgressbar -period 100 -maxphase 255 diff --git a/library/ttk/clamTheme.tcl b/library/ttk/clamTheme.tcl index 98f0036..67e89e6 100644 --- a/library/ttk/clamTheme.tcl +++ b/library/ttk/clamTheme.tcl @@ -131,8 +131,12 @@ namespace eval ttk::theme::clam { -font TkHeadingFont -relief raised -padding {3} ttk::style configure Treeview -background $colors(-window) ttk::style map Treeview \ - -background [list selected $colors(-selectbg)] \ - -foreground [list selected $colors(-selectfg)] ; + -background [list disabled $colors(-frame)\ + {!disabled !selected} $colors(-window) \ + selected $colors(-selectbg)] \ + -foreground [list disabled $colors(-disabledfg) \ + {!disabled !selected} black \ + selected $colors(-selectfg)] ttk::style configure TLabelframe \ -labeloutside true -labelmargins {0 0 0 4} \ diff --git a/library/ttk/classicTheme.tcl b/library/ttk/classicTheme.tcl index 3cb2b18..fefdb99 100644 --- a/library/ttk/classicTheme.tcl +++ b/library/ttk/classicTheme.tcl @@ -98,8 +98,12 @@ namespace eval ttk::theme::classic { ttk::style configure Heading -font TkHeadingFont -relief raised ttk::style configure Treeview -background $colors(-window) ttk::style map Treeview \ - -background [list selected $colors(-selectbg)] \ - -foreground [list selected $colors(-selectfg)] ; + -background [list disabled $colors(-frame)\ + {!disabled !selected} $colors(-window) \ + selected $colors(-selectbg)] \ + -foreground [list disabled $colors(-disabledfg) \ + {!disabled !selected} black \ + selected $colors(-selectfg)] # # Toolbar buttons: diff --git a/library/ttk/defaults.tcl b/library/ttk/defaults.tcl index 9cc5880..5018bf2 100644 --- a/library/ttk/defaults.tcl +++ b/library/ttk/defaults.tcl @@ -110,8 +110,12 @@ namespace eval ttk::theme::default { -background $colors(-window) \ -foreground $colors(-text) ; ttk::style map Treeview \ - -background [list selected $colors(-selectbg)] \ - -foreground [list selected $colors(-selectfg)] ; + -background [list disabled $colors(-frame)\ + {!disabled !selected} $colors(-window) \ + selected $colors(-selectbg)] \ + -foreground [list disabled $colors(-disabledfg) \ + {!disabled !selected} black \ + selected $colors(-selectfg)] # Combobox popdown frame ttk::style layout ComboboxPopdownFrame { diff --git a/library/ttk/vistaTheme.tcl b/library/ttk/vistaTheme.tcl index c6c380d..be68978 100644 --- a/library/ttk/vistaTheme.tcl +++ b/library/ttk/vistaTheme.tcl @@ -46,8 +46,12 @@ namespace eval ttk::theme::vista { ttk::style configure Heading -font TkHeadingFont ttk::style configure Treeview -background SystemWindow ttk::style map Treeview \ - -background [list selected SystemHighlight] \ - -foreground [list selected SystemHighlightText] ; + -background [list disabled SystemButtonFace \ + {!disabled !selected} SystemWindow \ + selected SystemHighlight] \ + -foreground [list disabled SystemGrayText \ + {!disabled !selected} SystemWindowText \ + selected SystemHighlightText] # Label and Toolbutton ttk::style configure TLabelframe.Label -foreground "#0046d5" diff --git a/library/ttk/winTheme.tcl b/library/ttk/winTheme.tcl index 55367bc..6c03ef6 100644 --- a/library/ttk/winTheme.tcl +++ b/library/ttk/winTheme.tcl @@ -71,8 +71,12 @@ namespace eval ttk::theme::winnative { ttk::style configure Heading -font TkHeadingFont -relief raised ttk::style configure Treeview -background SystemWindow ttk::style map Treeview \ - -background [list selected SystemHighlight] \ - -foreground [list selected SystemHighlightText] ; + -background [list disabled SystemButtonFace \ + {!disabled !selected} SystemWindow \ + selected SystemHighlight] \ + -foreground [list disabled SystemGrayText \ + {!disabled !selected} SystemWindowText \ + selected SystemHighlightText] ttk::style configure TProgressbar \ -background SystemHighlight -borderwidth 0 ; diff --git a/library/ttk/xpTheme.tcl b/library/ttk/xpTheme.tcl index 187ce0b..a174bfc 100644 --- a/library/ttk/xpTheme.tcl +++ b/library/ttk/xpTheme.tcl @@ -61,5 +61,15 @@ namespace eval ttk::theme::xpnative { ttk::style configure Toolbutton -padding {4 4} + # Treeview: + ttk::style configure Heading -font TkHeadingFont -relief raised + ttk::style configure Treeview -background SystemWindow + ttk::style map Treeview \ + -background [list disabled SystemButtonFace \ + {!disabled !selected} SystemWindow \ + selected SystemHighlight] \ + -foreground [list disabled SystemGrayText \ + {!disabled !selected} SystemWindowText \ + selected SystemHighlightText]; } } |