summaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
Diffstat (limited to 'library')
-rw-r--r--library/ttk/altTheme.tcl67
-rw-r--r--library/ttk/classicTheme.tcl57
2 files changed, 61 insertions, 63 deletions
diff --git a/library/ttk/altTheme.tcl b/library/ttk/altTheme.tcl
index bee578c..28b653c 100644
--- a/library/ttk/altTheme.tcl
+++ b/library/ttk/altTheme.tcl
@@ -1,5 +1,5 @@
#
-# $Id: altTheme.tcl,v 1.4 2007/11/18 19:20:26 jenglish Exp $
+# $Id: altTheme.tcl,v 1.5 2007/12/08 03:49:27 jenglish Exp $
#
# Ttk widget set: Alternate theme
#
@@ -17,10 +17,9 @@ namespace eval ttk::theme::alt {
-selectfg "#ffffff"
}
- namespace import -force ::ttk::style
- style theme settings alt {
+ ttk::style theme settings alt {
- style configure "." \
+ ttk::style configure "." \
-background $colors(-frame) \
-foreground black \
-troughcolor $colors(-darker) \
@@ -29,74 +28,74 @@ namespace eval ttk::theme::alt {
-font TkDefaultFont \
;
- style map "." -background \
+ ttk::style map "." -background \
[list disabled $colors(-frame) active $colors(-activebg)] ;
- style map "." -foreground [list disabled $colors(-disabledfg)] ;
- style map "." -embossed [list disabled 1] ;
+ ttk::style map "." -foreground [list disabled $colors(-disabledfg)] ;
+ ttk::style map "." -embossed [list disabled 1] ;
- style configure TButton \
+ ttk::style configure TButton \
-anchor center -width -11 -padding "1 1" \
-relief raised -shiftrelief 1 \
-highlightthickness 1 -highlightcolor $colors(-frame)
- style map TButton -relief {
+ ttk::style map TButton -relief {
{pressed !disabled} sunken
{active !disabled} raised
} -highlightcolor {alternate black}
- style configure TCheckbutton -indicatorcolor "#ffffff" -padding 2
- style configure TRadiobutton -indicatorcolor "#ffffff" -padding 2
- style map TCheckbutton -indicatorcolor \
+ ttk::style configure TCheckbutton -indicatorcolor "#ffffff" -padding 2
+ ttk::style configure TRadiobutton -indicatorcolor "#ffffff" -padding 2
+ ttk::style map TCheckbutton -indicatorcolor \
[list disabled $colors(-frame) pressed $colors(-frame)]
- style map TRadiobutton -indicatorcolor \
+ ttk::style map TRadiobutton -indicatorcolor \
[list disabled $colors(-frame) pressed $colors(-frame)]
- style configure TMenubutton \
+ ttk::style configure TMenubutton \
-width -11 -padding "3 3" -relief raised
- style configure TEntry -padding 1
- style map TEntry -fieldbackground \
+ ttk::style configure TEntry -padding 1
+ ttk::style map TEntry -fieldbackground \
[list readonly $colors(-frame) disabled $colors(-frame)]
- style configure TCombobox -padding 1
- style map TCombobox -fieldbackground \
+ ttk::style configure TCombobox -padding 1
+ ttk::style map TCombobox -fieldbackground \
[list readonly $colors(-frame) disabled $colors(-frame)]
- style configure Toolbutton -relief flat -padding 2
- style map Toolbutton -relief \
+ ttk::style configure Toolbutton -relief flat -padding 2
+ ttk::style map Toolbutton -relief \
{disabled flat selected sunken pressed sunken active raised}
- style map Toolbutton -background \
+ ttk::style map Toolbutton -background \
[list pressed $colors(-darker) active $colors(-activebg)]
- style configure TScrollbar -relief raised
+ ttk::style configure TScrollbar -relief raised
- style configure TLabelframe -relief groove -borderwidth 2
+ ttk::style configure TLabelframe -relief groove -borderwidth 2
- style configure TNotebook -tabmargins {2 2 1 0}
- style configure TNotebook.Tab \
+ ttk::style configure TNotebook -tabmargins {2 2 1 0}
+ ttk::style configure TNotebook.Tab \
-padding {4 2} -background $colors(-darker)
- style map TNotebook.Tab \
+ ttk::style map TNotebook.Tab \
-background [list selected $colors(-frame)] \
-expand [list selected {2 2 1 0}] \
;
# Treeview:
- style configure Heading -font TkHeadingFont -relief raised
- style configure Row -background $colors(-window)
- style configure Cell -background $colors(-window)
- style map Row \
+ ttk::style configure Heading -font TkHeadingFont -relief raised
+ ttk::style configure Row -background $colors(-window)
+ ttk::style configure Cell -background $colors(-window)
+ ttk::style map Row \
-background [list selected $colors(-selectbg)] \
-foreground [list selected $colors(-selectfg)] ;
- style map Cell \
+ ttk::style map Cell \
-background [list selected $colors(-selectbg)] \
-foreground [list selected $colors(-selectfg)] ;
- style map Item \
+ ttk::style map Item \
-background [list selected $colors(-selectbg)] \
-foreground [list selected $colors(-selectfg)] ;
- style configure TScale \
+ ttk::style configure TScale \
-groovewidth 4 -troughrelief sunken \
-sliderwidth raised -borderwidth 2
- style configure TProgressbar \
+ ttk::style configure TProgressbar \
-background $colors(-selectbg) -borderwidth 0
}
}
diff --git a/library/ttk/classicTheme.tcl b/library/ttk/classicTheme.tcl
index 38dc845..813c17f 100644
--- a/library/ttk/classicTheme.tcl
+++ b/library/ttk/classicTheme.tcl
@@ -1,5 +1,5 @@
#
-# $Id: classicTheme.tcl,v 1.4 2007/11/18 19:20:26 jenglish Exp $
+# $Id: classicTheme.tcl,v 1.5 2007/12/08 03:49:27 jenglish Exp $
#
# "classic" Tk theme.
#
@@ -19,9 +19,8 @@ namespace eval ttk::theme::classic {
-indicator "#b03060"
}
- namespace import -force ::ttk::style
- style theme settings classic {
- style configure "." \
+ ttk::style theme settings classic {
+ ttk::style configure "." \
-font TkDefaultFont \
-background $colors(-frame) \
-foreground black \
@@ -38,53 +37,53 @@ namespace eval ttk::theme::classic {
# To match pre-Xft X11 appearance, use:
# ttk::style configure . -font {Helvetica 12 bold}
- style map "." -background \
+ ttk::style map "." -background \
[list disabled $colors(-frame) active $colors(-activebg)]
- style map "." -foreground \
+ ttk::style map "." -foreground \
[list disabled $colors(-disabledfg)]
- style map "." -highlightcolor [list focus black]
+ ttk::style map "." -highlightcolor [list focus black]
- style configure TButton \
+ ttk::style configure TButton \
-anchor center -padding "3m 1m" -relief raised -shiftrelief 1
- style map TButton -relief [list {!disabled pressed} sunken]
+ ttk::style map TButton -relief [list {!disabled pressed} sunken]
- style configure TCheckbutton -indicatorrelief raised
- style map TCheckbutton \
+ ttk::style configure TCheckbutton -indicatorrelief raised
+ ttk::style map TCheckbutton \
-indicatorcolor [list \
pressed $colors(-frame) selected $colors(-indicator)] \
-indicatorrelief {selected sunken pressed sunken} \
;
- style configure TRadiobutton -indicatorrelief raised
- style map TRadiobutton \
+ ttk::style configure TRadiobutton -indicatorrelief raised
+ ttk::style map TRadiobutton \
-indicatorcolor [list \
pressed $colors(-frame) selected $colors(-indicator)] \
-indicatorrelief {selected sunken pressed sunken} \
;
- style configure TMenubutton -relief raised -padding "3m 1m"
+ ttk::style configure TMenubutton -relief raised -padding "3m 1m"
- style configure TEntry -relief sunken -padding 1 -font TkTextFont
- style map TEntry -fieldbackground \
+ ttk::style configure TEntry -relief sunken -padding 1 -font TkTextFont
+ ttk::style map TEntry -fieldbackground \
[list readonly $colors(-frame) disabled $colors(-frame)]
- style configure TCombobox -padding 1
- style map TCombobox -fieldbackground \
+ ttk::style configure TCombobox -padding 1
+ ttk::style map TCombobox -fieldbackground \
[list readonly $colors(-frame) disabled $colors(-frame)]
- style configure TLabelframe -borderwidth 2 -relief groove
+ ttk::style configure TLabelframe -borderwidth 2 -relief groove
- style configure TScrollbar -relief raised
- style map TScrollbar -relief {{pressed !disabled} sunken}
+ ttk::style configure TScrollbar -relief raised
+ ttk::style map TScrollbar -relief {{pressed !disabled} sunken}
- style configure TScale -sliderrelief raised
- style map TScale -sliderrelief {{pressed !disabled} sunken}
+ ttk::style configure TScale -sliderrelief raised
+ ttk::style map TScale -sliderrelief {{pressed !disabled} sunken}
- style configure TProgressbar -background SteelBlue
- style configure TNotebook.Tab \
+ ttk::style configure TProgressbar -background SteelBlue
+ ttk::style configure TNotebook.Tab \
-padding {3m 1m} \
-background $colors(-troughbg)
- style map TNotebook.Tab -background [list selected $colors(-frame)]
+ ttk::style map TNotebook.Tab -background [list selected $colors(-frame)]
# Treeview:
ttk::style configure Heading -font TkHeadingFont -relief raised
@@ -100,10 +99,10 @@ namespace eval ttk::theme::classic {
#
# Toolbar buttons:
#
- style configure Toolbutton -padding 2 -relief flat -shiftrelief 2
- style map Toolbutton -relief \
+ ttk::style configure Toolbutton -padding 2 -relief flat -shiftrelief 2
+ ttk::style map Toolbutton -relief \
{disabled flat selected sunken pressed sunken active raised}
- style map Toolbutton -background \
+ ttk::style map Toolbutton -background \
[list pressed $colors(-troughbg) active $colors(-activebg)]
}
}