diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c
index 15218c049..11ee5b1b2 100644
--- a/generic/tkCanvas.c
+++ b/generic/tkCanvas.c
@@ -691,6 +691,7 @@ Tk_CanvasObjCmd(
canvasPtr->confine = 0;
canvasPtr->textInfo.selBorder = NULL;
canvasPtr->textInfo.selBorderWidth = 0;
+ canvasPtr->textInfo.reserved3 = NULL;
canvasPtr->textInfo.selFgColorPtr = NULL;
canvasPtr->textInfo.selItemPtr = NULL;
canvasPtr->textInfo.selectFirst = TCL_INDEX_NONE;
@@ -699,7 +700,9 @@ Tk_CanvasObjCmd(
canvasPtr->textInfo.selectAnchor = 0;
canvasPtr->textInfo.insertBorder = NULL;
canvasPtr->textInfo.insertWidth = 0;
+ canvasPtr->textInfo.reserved2 = NULL;
canvasPtr->textInfo.insertBorderWidth = 0;
+ canvasPtr->textInfo.reserved1 = NULL;
canvasPtr->textInfo.focusItemPtr = NULL;
canvasPtr->textInfo.gotFocus = 0;
canvasPtr->textInfo.cursorOn = 0;
diff --git a/generic/tkMenubutton.h b/generic/tkMenubutton.h
index 9d1a5ab56..06502dfad 100644
--- a/generic/tkMenubutton.h
+++ b/generic/tkMenubutton.h
@@ -171,7 +171,7 @@ typedef struct {
Tk_Cursor cursor; /* Current cursor for window, or NULL. */
Tcl_Obj *takeFocusObj; /* Value of -takefocus option; not used in the
* C code, but used by keyboard traversal
- * scripts. Malloc'ed, but may be NULL. */
+ * scripts. May be NULL. */
int flags; /* Various flags; see below for
* definitions. */
#ifdef BUILD_tk
diff --git a/library/bgerror.tcl b/library/bgerror.tcl
index e74faf2a3..a4147c3db 100644
--- a/library/bgerror.tcl
+++ b/library/bgerror.tcl
@@ -22,7 +22,7 @@ namespace eval ::tk::dialog::error {
option add *ErrorDialog*background systemAlertBackgroundActive \
widgetDefault
option add *ErrorDialog*info.text.background \
- systemTextBackgroundColor widgetDefault
+ systemTextBackgroundColor widgetDefault
option add *ErrorDialog*Button.highlightBackground \
systemAlertBackgroundActive widgetDefault
}
diff --git a/library/demos/images/Tcl.svg b/library/demos/images/Tcl.svg
index 2c18ec16d..05dd9a46a 100644
--- a/library/demos/images/Tcl.svg
+++ b/library/demos/images/Tcl.svg
@@ -40,10 +40,10 @@
id="metadata2314">
- image/svg+xml
-
+ rdf:about="">
+ image/svg+xml
+
@@ -53,23 +53,23 @@
id="layer1"
transform="translate(-311.79308,-365.73272)">
+ style="opacity:1;display:inline"
+ id="g2244"
+ transform="translate(308.95998,366.42022)">
+ id="path4426"
+ d="M 445.52492,372.22514 C 445.90652,395.55723 445.21415,418.63757 425.02492,440.56889 L 424.27492,441.41264 L 425.39992,441.41264 L 433.64992,441.53764 C 420.24442,469.42405 411.52244,497.23134 392.24367,525.00639 L 391.55617,526.00639 L 392.74367,525.78764 L 402.93117,523.85014 C 395.71427,542.16045 383.37359,554.28293 369.99367,558.35014 C 366.31107,506.78151 392.04593,461.26308 413.89992,415.88139 C 413.92002,415.83965 413.94233,415.79813 413.96242,415.75639 L 413.14992,415.19389 C 377.36425,455.2074 361.23872,511.6427 355.14992,558.19389 C 343.02146,551.34666 338.97913,542.28079 334.86867,529.94389 L 343.33742,533.50639 L 344.21242,533.88139 L 344.02492,532.94389 C 337.58858,504.32416 347.5814,483.78143 357.27492,456.78764 L 364.24367,461.44389 L 365.05617,462.00639 L 365.02492,461.03764 C 364.47892,439.10645 379.24595,417.08983 398.83742,397.44389 L 401.55617,404.72514 L 401.93117,405.69389 L 402.46242,404.78764 L 408.43117,394.85014 L 408.46242,394.78764 C 418.31429,381.21812 428.72988,376.80082 445.52492,372.22514 z "
+ style="fill:#c3b15f;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;display:inline"
+ transform="translate(-324.02492,-364.63139)" />
+ sodipodi:nodetypes="ccccccccccccccccccccccc"
+ id="path7600"
+ d="M 121.54988,7.5808058 C 104.81215,12.147023 94.270242,16.613077 84.4375,30.15625 L 84.40625,30.21875 L 78.4375,40.15625 L 77.90625,41.0625 L 77.53125,40.09375 L 74.8125,32.8125 C 55.22103,52.45844 40.454,74.47506 41,96.40625 L 41.03125,97.375 L 40.21875,96.8125 L 33.25,92.15625 C 23.55648,119.15004 13.56366,139.69277 20,168.3125 L 20.1875,169.25 L 19.3125,168.875 L 10.9375,165.34375 C 10.96447,165.51523 11.003113,165.67421 11.03125,165.84375 C 15.080346,177.9015 19.176955,186.81713 31.125,193.5625 C 31.596616,189.95681 32.122231,186.27456 32.71875,182.5625 C 18.12816,148.39836 30.79293,123.2814 36.5625,100.6875 L 45.4375,105.8125 C 44.211577,84.657017 56.63174,61.842112 72.78125,41.9375 L 77.46875,50.1875 C 89.477498,25.486664 98.97512,15.57175 121.54988,7.5808058 z "
+ style="opacity:1;fill:#eff1cb;fill-opacity:1;fill-rule:evenodd;stroke:#eff1cb;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;display:inline" />
+ style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;display:inline"
+ d="M 126.9375,-0.6875 L 126.40625,-0.59375 C 106.72165,2.83976 87.4508,10.07244 79,27.375 L 75.4375,21.15625 L 75.125,20.59375 L 74.65625,21.0625 C 64.96254,30.33838 54.55574,42.35306 46.875,54.15625 C 39.66528,65.23562 34.88327,76.07934 35.40625,84.375 L 30.375,78.09375 L 29.875,77.46875 L 29.53125,78.1875 C 23.40732,91.41649 17.22694,107.69157 13.53125,122.625 C 10.02725,136.78385 8.77244,149.67206 12.03125,157.78125 L 3.75,152.96875 L 3.0625,152.5625 L 3,153.375 C 1.44089,176.99202 11.0382,188.26833 22.0625,199.15625 L 12.875,201.4375 L 11.03125,201.90625 L 12.875,202.40625 C 18.14953,203.83558 23.15023,205.44485 26.625,208.125 C 30.09977,210.80515 32.09598,214.49082 31.5,220.375 L 31.5,220.40625 L 31.5,245.90625 L 31.5,246.0625 L 31.59375,246.1875 L 43.09375,262.6875 L 44,264 L 44,262.40625 L 44,223.53125 C 45.52181,216.98735 47.30807,212.4833 49.875,209.5 C 52.44193,206.5167 55.78211,204.98483 60.5625,204.40625 L 62.28125,204.1875 L 60.71875,203.46875 L 54.65625,200.59375 C 69.11174,191.89001 85.3013,170.55445 89.5625,150.28125 L 89.75,149.46875 L 88.96875,149.6875 L 81.46875,151.71875 C 88.13174,145.46249 94.84392,133.06721 101.21875,118.625 C 107.9798,103.3078 114.29247,85.96032 119.46875,72.09375 L 119.75,71.34375 L 118.96875,71.40625 L 113.1875,71.8125 C 120.3346,64.22669 124.30703,51.6996 126.25,38.46875 C 128.27227,24.69793 128.13035,10.1977 127,-0.15625 L 126.9375,-0.6875 z M 121.5,7.59375 C 121.8816,30.92584 121.18923,54.00618 101,75.9375 L 100.25,76.78125 L 101.375,76.78125 L 109.625,76.90625 C 96.2195,104.79266 87.49752,132.59995 68.21875,160.375 L 67.53125,161.375 L 68.71875,161.15625 L 78.90625,159.21875 C 71.68935,177.52906 59.34867,189.65154 45.96875,193.71875 C 42.28615,142.15012 68.02101,96.63169 89.875,51.25 C 89.8951,51.20826 89.91741,51.16674 89.9375,51.125 L 89.125,50.5625 C 53.33933,90.57601 37.2138,147.01131 31.125,193.5625 C 18.99654,186.71527 14.95421,177.6494 10.84375,165.3125 L 19.3125,168.875 L 20.1875,169.25 L 20,168.3125 C 13.56366,139.69277 23.55648,119.15004 33.25,92.15625 L 40.21875,96.8125 L 41.03125,97.375 L 41,96.40625 C 40.454,74.47506 55.22103,52.45844 74.8125,32.8125 L 77.53125,40.09375 L 77.90625,41.0625 L 78.4375,40.15625 L 84.40625,30.21875 L 84.4375,30.15625 C 94.28937,16.58673 104.70496,12.16943 121.5,7.59375 z "
+ id="path2177" />
diff --git a/library/demos/knightstour.tcl b/library/demos/knightstour.tcl
index d6a58d6b2..8da89baab 100644
--- a/library/demos/knightstour.tcl
+++ b/library/demos/knightstour.tcl
@@ -58,12 +58,12 @@ proc Next {square} {
if {[lsearch -exact -integer $visited $testSquare] < 0} {
set count [CheckSquare $testSquare]
if {$count < $minimum} {
- set minimum $count
- set nextSquare $testSquare
+ set minimum $count
+ set nextSquare $testSquare
} elseif {$count == $minimum} {
- # to remove the enhancement to Warnsdorff's rule
- # remove the next line:
- set nextSquare [Edgemost $nextSquare $testSquare]
+ # to remove the enhancement to Warnsdorff's rule
+ # remove the next line:
+ set nextSquare [Edgemost $nextSquare $testSquare]
}
}
}
@@ -104,13 +104,13 @@ proc MovePiece {dlg last square} {
if {[llength $visited] == 64} {
variable initial
if {$initial == $square} {
- $dlg.f.txt insert end "Closed tour!"
+ $dlg.f.txt insert end "Closed tour!"
} else {
- $dlg.f.txt insert end "Success"
- if {$continuous} {
- after [expr {$delay * 2}] [namespace code \
- [list Tour $dlg [expr {int(rand() * 64)}]]]
- }
+ $dlg.f.txt insert end "Success"
+ if {$continuous} {
+ after [expr {$delay * 2}] [namespace code \
+ [list Tour $dlg [expr {int(rand() * 64)}]]]
+ }
}
} else {
$dlg.f.txt insert end "FAILED!"
@@ -195,16 +195,16 @@ proc CreateGUI {} {
for {set row 7} {$row >= 0} {incr row -1} {
for {set col 0} {$col < 8} {incr col} {
if {(($col & 1) ^ ($row & 1))} {
- set fill tan3 ; set dfill tan4
+ set fill tan3 ; set dfill tan4
} else {
- set fill bisque ; set dfill bisque3
+ set fill bisque ; set dfill bisque3
}
set coords [list [expr {$col * 24 + 3}]p \
[expr {$row * 24 + 3}]p \
- [expr {$col * 24 + 24}]p \
+ [expr {$col * 24 + 24}]p \
[expr {$row * 24 + 24}]p]
$c create rectangle $coords -fill $fill -disabledfill $dfill \
- -width 1.5p -state disabled -outline black
+ -width 1.5p -state disabled -outline black
}
}
if {[tk windowingsystem] ne "x11"} {
diff --git a/library/fontchooser.tcl b/library/fontchooser.tcl
index b1b9d083b..c53d1d653 100644
--- a/library/fontchooser.tcl
+++ b/library/fontchooser.tcl
@@ -62,7 +62,7 @@ proc ::tk::fontchooser::Setup {} {
}
bind [winfo class .] <> \
[list +ttk::style layout FontchooserFrame \
- [ttk::style layout FontchooserFrame]]
+ [ttk::style layout FontchooserFrame]]
namespace ensemble create -map {
show ::tk::fontchooser::Show
@@ -115,10 +115,10 @@ proc ::tk::fontchooser::Configure {args} {
foreach spec $specs {
foreach {name xx yy default} $spec break
lappend result $name \
- [expr {[info exists S($name)] ? $S($name) : $default}]
+ [expr {[info exists S($name)] ? $S($name) : $default}]
}
lappend result -visible \
- [expr {[winfo exists $S(W)] && [winfo ismapped $S(W)]}]
+ [expr {[winfo exists $S(W)] && [winfo ismapped $S(W)]}]
return $result
}
if {[llength $args] == 1} {
@@ -129,8 +129,8 @@ proc ::tk::fontchooser::Configure {args} {
return $S($option)
}
return -code error -errorcode [list TK LOOKUP OPTION $option] \
- "bad option \"$option\": must be\
- -command, -font, -parent, -title or -visible"
+ "bad option \"$option\": must be\
+ -command, -font, -parent, -title or -visible"
}
set cache [dict create -parent $S(-parent) -title $S(-title) \
-font $S(-font) -command $S(-command)]
@@ -183,40 +183,40 @@ proc ::tk::fontchooser::Create {} {
::tk::AmpWidget ::ttk::label $S(W).style -text [::msgcat::mc "Font st&yle:"]
::tk::AmpWidget ::ttk::label $S(W).size -text [::msgcat::mc "&Size:"]
ttk::entry $S(W).efont -width 18 \
- -textvariable [namespace which -variable S](font)
+ -textvariable [namespace which -variable S](font)
ttk::entry $S(W).estyle -width 10 \
- -textvariable [namespace which -variable S](style)
+ -textvariable [namespace which -variable S](style)
ttk::entry $S(W).esize -textvariable [namespace which -variable S](size) \
- -width 3 -validate key -validatecommand {regexp -- {^-*[0-9]*$} %P}
+ -width 3 -validate key -validatecommand {regexp -- {^-*[0-9]*$} %P}
ttk_slistbox $S(W).lfonts -height 7 -exportselection 0 \
- -selectmode browse -activestyle none \
- -listvariable [namespace which -variable S](fonts)
+ -selectmode browse -activestyle none \
+ -listvariable [namespace which -variable S](fonts)
ttk_slistbox $S(W).lstyles -width 5 -height 7 -exportselection 0 \
- -selectmode browse -activestyle none \
- -listvariable [namespace which -variable S](styles)
+ -selectmode browse -activestyle none \
+ -listvariable [namespace which -variable S](styles)
ttk_slistbox $S(W).lsizes -width 4 -height 7 -exportselection 0 \
- -selectmode browse -activestyle none \
- -listvariable [namespace which -variable S](sizes)
+ -selectmode browse -activestyle none \
+ -listvariable [namespace which -variable S](sizes)
set WE $S(W).effects
::ttk::labelframe $WE -text [::msgcat::mc "Effects"]
::tk::AmpWidget ::ttk::checkbutton $WE.strike \
- -variable [namespace which -variable S](strike) \
- -text [::msgcat::mc "Stri&keout"] \
- -command [namespace code [list Click strike]]
+ -variable [namespace which -variable S](strike) \
+ -text [::msgcat::mc "Stri&keout"] \
+ -command [namespace code [list Click strike]]
::tk::AmpWidget ::ttk::checkbutton $WE.under \
- -variable [namespace which -variable S](under) \
- -text [::msgcat::mc "&Underline"] \
- -command [namespace code [list Click under]]
+ -variable [namespace which -variable S](under) \
+ -text [::msgcat::mc "&Underline"] \
+ -command [namespace code [list Click under]]
set bbox [::ttk::frame $S(W).bbox]
::ttk::button $S(W).ok -text [::msgcat::mc OK] -default active\
- -command [namespace code [list Done 1]]
+ -command [namespace code [list Done 1]]
::ttk::button $S(W).cancel -text [::msgcat::mc Cancel] \
- -command [namespace code [list Done 0]]
+ -command [namespace code [list Done 0]]
::tk::AmpWidget ::ttk::button $S(W).apply -text [::msgcat::mc "&Apply"] \
- -command [namespace code [list Apply]]
+ -command [namespace code [list Apply]]
wm protocol $S(W) WM_DELETE_WINDOW [namespace code [list Done 0]]
# Calculate minimum sizes
@@ -226,11 +226,11 @@ proc ::tk::fontchooser::Create {} {
set minsize(gap) [::tk::ScaleNum 10]
set minsize(bbox) [winfo reqwidth $S(W).ok]
set minsize(fonts) \
- [expr {[font measure TkDefaultFont "Helvetica"] + $scroll_width}]
+ [expr {[font measure TkDefaultFont "Helvetica"] + $scroll_width}]
set minsize(styles) \
- [expr {[font measure TkDefaultFont "Bold Italic"] + $scroll_width}]
+ [expr {[font measure TkDefaultFont "Bold Italic"] + $scroll_width}]
set minsize(sizes) \
- [expr {[font measure TkDefaultFont "-99"] + $scroll_width}]
+ [expr {[font measure TkDefaultFont "-99"] + $scroll_width}]
set min [expr {$minsize(gap) * 4}]
foreach {what width} [array get minsize] {
incr min $width
@@ -256,7 +256,7 @@ proc ::tk::fontchooser::Create {} {
set WS $S(W).sample
::ttk::labelframe $WS -text [::msgcat::mc "Sample"]
::ttk::label $WS.sample -relief sunken -anchor center \
- -textvariable [namespace which -variable S](sampletext)
+ -textvariable [namespace which -variable S](sampletext)
set S(sample) $WS.sample
grid $WS.sample -sticky news -padx 4.5p -pady 3p
grid rowconfigure $WS 0 -weight 1
@@ -292,15 +292,15 @@ proc ::tk::fontchooser::Create {} {
Init $S(-font)
trace add variable [namespace which -variable S](size) \
- write [namespace code [list Tracer]]
+ write [namespace code [list Tracer]]
trace add variable [namespace which -variable S](style) \
- write [namespace code [list Tracer]]
+ write [namespace code [list Tracer]]
trace add variable [namespace which -variable S](font) \
- write [namespace code [list Tracer]]
+ write [namespace code [list Tracer]]
trace add variable [namespace which -variable S](strike) \
- write [namespace code [list Tracer]]
+ write [namespace code [list Tracer]]
trace add variable [namespace which -variable S](under) \
- write [namespace code [list Tracer]]
+ write [namespace code [list Tracer]]
}
Init $S(-font)
@@ -422,19 +422,19 @@ proc ::tk::fontchooser::Tracer {var1 var2 op} {
$S(W).e$var2 icursor end
$S(W).e$var2 selection clear
if {[set i [lsearch $S(bad) $var2]] >= 0} {
- set S(bad) [lreplace $S(bad) $i $i]
+ set S(bad) [lreplace $S(bad) $i $i]
}
} else {
# No match, try prefix
set n [lsearch -glob $S(${var2}s,lcase) "$value*"]
if {$var2 ne "size" || !([regexp -- {^(-[0-9]+|[0-9]+)$} $value] && $value >= -4096 && $value <= 4096)} {
- if {[lsearch $S(bad) $var2] < 0} {
- lappend S(bad) $var2
- }
+ if {[lsearch $S(bad) $var2] < 0} {
+ lappend S(bad) $var2
+ }
} else {
- if {[set i [lsearch $S(bad) $var2]] >= 0} {
- set S(bad) [lreplace $S(bad) $i $i]
- }
+ if {[set i [lsearch $S(bad) $var2]] >= 0} {
+ set S(bad) [lreplace $S(bad) $i $i]
+ }
}
}
$S(W).l${var2}s see $n
diff --git a/library/iconbadges.tcl b/library/iconbadges.tcl
index 42ff2f7b8..5dc6f5a26 100644
--- a/library/iconbadges.tcl
+++ b/library/iconbadges.tcl
@@ -220,7 +220,7 @@ if {[tk windowingsystem] eq "x11"} {
}
if {!([string is integer -strict $badgenumber] && $badgenumber > 0)
- && $badgenumber ne "!" && $badgenumber ne ""} {
+ && $badgenumber ne "!" && $badgenumber ne ""} {
return -code error "can't use \"$badgenumber\" as icon badge"
}
diff --git a/library/menu.tcl b/library/menu.tcl
index 9e58749ed..9a6dec4f1 100644
--- a/library/menu.tcl
+++ b/library/menu.tcl
@@ -1199,18 +1199,18 @@ if {[tk windowingsystem] eq "aqua"} {
incr x [expr {[winfo width $button]}]
}
default { # flush
- if {[$button cget -indicatoron]} {
- if {$cx ne ""} {
- set x [expr {$cx - [winfo reqwidth $menu] / 2}]
- set l [font metrics [$menu cget -font] -linespace]
- set y [expr {$cy - $l/2 - 2}]
- } else {
- incr x [expr {([winfo width $button] - \
+ if {[$button cget -indicatoron]} {
+ if {$cx ne ""} {
+ set x [expr {$cx - [winfo reqwidth $menu] / 2}]
+ set l [font metrics [$menu cget -font] -linespace]
+ set y [expr {$cy - $l/2 - 2}]
+ } else {
+ incr x [expr {([winfo width $button] - \
[winfo reqwidth $menu])/ 2}]
- }
- } else {
- incr y [winfo height $button]
- }
+ }
+ } else {
+ incr y [winfo height $button]
+ }
}
}
PostOverPoint $menu $x $y $entry
diff --git a/library/msgbox.tcl b/library/msgbox.tcl
index 1ea5833b4..cb39a1ca7 100644
--- a/library/msgbox.tcl
+++ b/library/msgbox.tcl
@@ -325,18 +325,18 @@ proc ::tk::MessageBox {args} {
label $w.bitmap -bitmap $data(-icon) -background $bg
} else {
switch $data(-icon) {
- error {
- ttk::label $w.bitmap -image ::tk::icons::error
- }
- info {
- ttk::label $w.bitmap -image ::tk::icons::information
- }
- question {
- ttk::label $w.bitmap -image ::tk::icons::question
- }
- default {
- ttk::label $w.bitmap -image ::tk::icons::warning
- }
+ error {
+ ttk::label $w.bitmap -image ::tk::icons::error
+ }
+ info {
+ ttk::label $w.bitmap -image ::tk::icons::information
+ }
+ question {
+ ttk::label $w.bitmap -image ::tk::icons::question
+ }
+ default {
+ ttk::label $w.bitmap -image ::tk::icons::warning
+ }
}
}
}
diff --git a/library/spinbox.tcl b/library/spinbox.tcl
index d29ceb6ec..54eb70920 100644
--- a/library/spinbox.tcl
+++ b/library/spinbox.tcl
@@ -355,7 +355,7 @@ proc ::tk::spinbox::ArrowPress {w x y} {
set delay [$w cget -repeatdelay]
if {$delay > 0} {
set Priv(afterId) [after $delay \
- [list ::tk::spinbox::Invoke $w $Priv(element)]]
+ [list ::tk::spinbox::Invoke $w $Priv(element)]]
}
if {[info exists Priv(outsideElement)]} {
unset Priv(outsideElement)
diff --git a/library/ttk/altTheme.tcl b/library/ttk/altTheme.tcl
index 156e3c200..c37edede7 100644
--- a/library/ttk/altTheme.tcl
+++ b/library/ttk/altTheme.tcl
@@ -49,12 +49,12 @@ namespace eval ttk::theme::alt {
-indicatormargin {0 1.5p 3p 1.5p} -padding 1.5p
ttk::style map TCheckbutton -indicatorcolor \
[list pressed $colors(-frame) \
- alternate $colors(-altindicator) \
- disabled $colors(-frame)]
+ alternate $colors(-altindicator) \
+ disabled $colors(-frame)]
ttk::style map TRadiobutton -indicatorcolor \
[list pressed $colors(-frame) \
- alternate $colors(-altindicator) \
- disabled $colors(-frame)]
+ alternate $colors(-altindicator) \
+ disabled $colors(-frame)]
ttk::style configure TMenubutton \
-width -11 -padding 2.25p -arrowsize 3.75p -relief raised
diff --git a/library/ttk/aquaTheme.tcl b/library/ttk/aquaTheme.tcl
index b2c699222..dfefbbdd0 100644
--- a/library/ttk/aquaTheme.tcl
+++ b/library/ttk/aquaTheme.tcl
@@ -30,8 +30,8 @@ namespace eval ttk::theme::aqua {
ttk::style map TButton \
-foreground {
pressed white
- {alternate !pressed !background} white
- disabled systemDisabledControlTextColor}
+ {alternate !pressed !background} white
+ disabled systemDisabledControlTextColor}
# Menubutton
ttk::style configure TMenubutton -anchor center -padding {2 0 0 2}
diff --git a/library/ttk/menubutton.tcl b/library/ttk/menubutton.tcl
index 4f515498b..168ebb247 100644
--- a/library/ttk/menubutton.tcl
+++ b/library/ttk/menubutton.tcl
@@ -138,7 +138,7 @@ if {[tk windowingsystem] eq "aqua"} {
# if we go offscreen to the top, show as 'below'
if {$y < [winfo vrooty $mb]} {
set y [expr {[winfo vrooty $mb] + [winfo rooty $mb]\
- + [winfo reqheight $mb]}]
+ + [winfo reqheight $mb]}]
}
}
below {
diff --git a/library/ttk/treeview.tcl b/library/ttk/treeview.tcl
index 02ac4e01d..6421197d7 100644
--- a/library/ttk/treeview.tcl
+++ b/library/ttk/treeview.tcl
@@ -76,7 +76,7 @@ proc ttk::treeview::Keynav {w dir} {
switch -- $dir {
up {
if {[set up [$w prev $focus]] eq ""} {
- set focus [$w parent $focus]
+ set focus [$w parent $focus]
} else {
while {[$w item $up -open] && [llength [$w children $up]]} {
set up [lindex [$w children $up] end]
@@ -86,7 +86,7 @@ proc ttk::treeview::Keynav {w dir} {
}
down {
if {[$w item $focus -open] && [llength [$w children $focus]]} {
- set focus [lindex [$w children $focus] 0]
+ set focus [lindex [$w children $focus] 0]
} else {
set up $focus
while {$up ne "" && [set down [$w next $up]] eq ""} {
@@ -97,13 +97,13 @@ proc ttk::treeview::Keynav {w dir} {
}
left {
if {$cells} {
- # This assumes that colAnchor is of the "#N" format.
- set colNo [string range $colAnchor 1 end]
- set firstCol [expr {"tree" ni [$w cget -show]}]
- if {$colNo > $firstCol} {
- incr colNo -1
- set colAnchor "#$colNo"
- }
+ # This assumes that colAnchor is of the "#N" format.
+ set colNo [string range $colAnchor 1 end]
+ set firstCol [expr {"tree" ni [$w cget -show]}]
+ if {$colNo > $firstCol} {
+ incr colNo -1
+ set colAnchor "#$colNo"
+ }
} elseif {[$w item $focus -open] && [llength [$w children $focus]]} {
CloseItem $w $focus
} else {
@@ -112,19 +112,19 @@ proc ttk::treeview::Keynav {w dir} {
}
right {
if {$cells} {
- set colNo [string range $colAnchor 1 end]
- set dispCol [$w cget -displaycolumns]
- if {$dispCol eq "#all"} {
- set lastCol [llength [$w cget -columns]]
- } else {
- set lastCol [llength $dispCol]
- }
- if {$colNo < ($lastCol - 1)} {
- incr colNo
- set colAnchor "#$colNo"
- }
+ set colNo [string range $colAnchor 1 end]
+ set dispCol [$w cget -displaycolumns]
+ if {$dispCol eq "#all"} {
+ set lastCol [llength [$w cget -columns]]
+ } else {
+ set lastCol [llength $dispCol]
+ }
+ if {$colNo < ($lastCol - 1)} {
+ incr colNo
+ set colAnchor "#$colNo"
+ }
} else {
- OpenItem $w $focus
+ OpenItem $w $focus
}
}
}
diff --git a/library/ttk/ttk.tcl b/library/ttk/ttk.tcl
index debbc0e60..79dffec2a 100644
--- a/library/ttk/ttk.tcl
+++ b/library/ttk/ttk.tcl
@@ -178,7 +178,7 @@ proc ttk::LoadThemes {} {
} {
if {[lsearch -exact $builtinThemes $theme] >= 0} {
foreach script $scripts {
- uplevel #0 [list source -encoding utf-8 [file join $library $script]]
+ uplevel #0 [list source -encoding utf-8 [file join $library $script]]
}
}
}
diff --git a/library/ttk/vistaTheme.tcl b/library/ttk/vistaTheme.tcl
index bbddb8c2f..b0b814347 100644
--- a/library/ttk/vistaTheme.tcl
+++ b/library/ttk/vistaTheme.tcl
@@ -42,9 +42,9 @@ namespace eval ttk::theme::vista {
# Treeview:
ttk::style configure Heading -font TkHeadingFont
ttk::style configure Treeview -background SystemWindow \
- -stripedbackground System3dLight
+ -stripedbackground System3dLight
ttk::style configure Treeview.Separator \
- -background System3dLight
+ -background System3dLight
ttk::style map Treeview \
-background [list disabled SystemButtonFace \
selected SystemHighlight] \
@@ -67,14 +67,14 @@ namespace eval ttk::theme::vista {
-syssize {SM_CXVSCROLL SM_CYVSCROLL}
ttk::style layout TCombobox {
Combobox.border -sticky nswe -border 0 -children {
- Combobox.rightdownarrow -side right -sticky ns
- Combobox.padding -sticky nswe -children {
- Combobox.background -sticky nswe -children {
- Combobox.focus -sticky nswe -children {
- Combobox.textarea -sticky nswe
- }
- }
- }
+ Combobox.rightdownarrow -side right -sticky ns
+ Combobox.padding -sticky nswe -children {
+ Combobox.background -sticky nswe -children {
+ Combobox.focus -sticky nswe -children {
+ Combobox.textarea -sticky nswe
+ }
+ }
+ }
}
}
# Vista.Combobox droplist frame
@@ -82,7 +82,7 @@ namespace eval ttk::theme::vista {
LISTBOX 3 {disabled 4 active 3 focus 2 {} 1}
ttk::style layout ComboboxPopdownFrame {
ComboboxPopdownFrame.background -sticky news -border 1 -children {
- ComboboxPopdownFrame.padding -sticky news
+ ComboboxPopdownFrame.padding -sticky news
}
}
ttk::style map TCombobox \
@@ -102,11 +102,11 @@ namespace eval ttk::theme::vista {
EDIT 3 {disabled 3 readonly 3 focus 4 hover 2 {} 1}
ttk::style layout TEntry {
Entry.field -sticky news -border 0 -children {
- Entry.background -sticky news -children {
- Entry.padding -sticky news -children {
- Entry.textarea -sticky news
- }
- }
+ Entry.background -sticky news -children {
+ Entry.padding -sticky news -children {
+ Entry.textarea -sticky news
+ }
+ }
}
}
ttk::style map TEntry \
@@ -132,15 +132,15 @@ namespace eval ttk::theme::vista {
-syssize { SM_CXVSCROLL SM_CYVSCROLL }
ttk::style layout TSpinbox {
Spinbox.field -sticky nswe -children {
- Spinbox.background -sticky news -children {
- Spinbox.padding -sticky news -children {
- Spinbox.innerbg -sticky news -children {
- Spinbox.textarea
- }
- }
- Spinbox.uparrow -side top -sticky ens
- Spinbox.downarrow -side bottom -sticky ens
- }
+ Spinbox.background -sticky news -children {
+ Spinbox.padding -sticky news -children {
+ Spinbox.innerbg -sticky news -children {
+ Spinbox.textarea
+ }
+ }
+ Spinbox.uparrow -side top -sticky ens
+ Spinbox.downarrow -side bottom -sticky ens
+ }
}
}
ttk::style map TSpinbox \
@@ -182,15 +182,15 @@ namespace eval ttk::theme::vista {
PROGRESS 3 {{} 1} -padding 8
ttk::style layout Horizontal.TProgressbar {
Horizontal.Progressbar.trough -sticky nswe -children {
- Horizontal.Progressbar.pbar -side left -sticky ns
- Horizontal.Progressbar.ctext -sticky nesw
+ Horizontal.Progressbar.pbar -side left -sticky ns
+ Horizontal.Progressbar.ctext -sticky nesw
}
}
ttk::style element create Vertical.Progressbar.pbar vsapi \
PROGRESS 3 {{} 1} -padding 8
ttk::style layout Vertical.TProgressbar {
Vertical.Progressbar.trough -sticky nswe -children {
- Vertical.Progressbar.pbar -side bottom -sticky we
+ Vertical.Progressbar.pbar -side bottom -sticky we
}
}
@@ -200,10 +200,10 @@ namespace eval ttk::theme::vista {
-width 6 -height 12
ttk::style layout Horizontal.TScale {
Scale.focus -sticky nswe -children {
- Horizontal.Scale.trough -sticky nswe -children {
- Horizontal.Scale.track -sticky we
- Horizontal.Scale.slider -side left -sticky {}
- }
+ Horizontal.Scale.trough -sticky nswe -children {
+ Horizontal.Scale.track -sticky we
+ Horizontal.Scale.slider -side left -sticky {}
+ }
}
}
ttk::style element create Vertical.Scale.slider vsapi \
@@ -211,10 +211,10 @@ namespace eval ttk::theme::vista {
-width 12 -height 6
ttk::style layout Vertical.TScale {
Scale.focus -sticky nswe -children {
- Vertical.Scale.trough -sticky nswe -children {
- Vertical.Scale.track -sticky ns
- Vertical.Scale.slider -side top -sticky {}
- }
+ Vertical.Scale.trough -sticky nswe -children {
+ Vertical.Scale.track -sticky ns
+ Vertical.Scale.slider -side top -sticky {}
+ }
}
}
diff --git a/tests/bgerror.test b/tests/bgerror.test
index bd383102e..eda8ba6c7 100644
--- a/tests/bgerror.test
+++ b/tests/bgerror.test
@@ -13,8 +13,8 @@ tcltest::loadTestedCommands
test bgerror-1.1 {bgerror / tkerror compat} -setup {
set errRes {}
proc tkerror {err} {
- global errRes;
- set errRes $err;
+ global errRes;
+ set errRes $err;
}
} -body {
after 0 {error err1}
@@ -27,8 +27,8 @@ test bgerror-1.1 {bgerror / tkerror compat} -setup {
test bgerror-1.2 {bgerror / tkerror compat / accumulation} -setup {
set errRes {}
proc tkerror {err} {
- global errRes;
- lappend errRes $err;
+ global errRes;
+ lappend errRes $err;
}
} -body {
after 0 {error err1}
@@ -43,9 +43,9 @@ test bgerror-1.2 {bgerror / tkerror compat / accumulation} -setup {
test bgerror-1.3 {bgerror / tkerror compat / accumulation / break} -setup {
set errRes {}
proc tkerror {err} {
- global errRes;
- lappend errRes $err;
- return -code break "skip!";
+ global errRes;
+ lappend errRes $err;
+ return -code break "skip!";
}
} -body {
after 0 {error err1}
diff --git a/tests/bind.test b/tests/bind.test
index efccdf3b5..b536d3515 100644
--- a/tests/bind.test
+++ b/tests/bind.test
@@ -342,11 +342,11 @@ test bind-9.2 {Tk_DeleteBinding procedure} -setup {
} -body {
frame .t.f -class Test -width 150 -height 100
foreach i {a b c d} {
- bind .t.f $i "binding for $i"
+ bind .t.f $i "binding for $i"
}
foreach i {b d a c} {
- bind .t.f $i {}
- lappend result [lsort [bind .t.f]]
+ bind .t.f $i {}
+ lappend result [lsort [bind .t.f]]
}
return $result
} -cleanup {
@@ -357,11 +357,11 @@ test bind-9.3 {Tk_DeleteBinding procedure} -setup {
} -body {
frame .t.f -class Test -width 150 -height 100
foreach i { } {
- bind .t.f $i "binding for $i"
+ bind .t.f $i "binding for $i"
}
foreach i { } {
- bind .t.f $i {}
- lappend result [lsort [bind .t.f]]
+ bind .t.f $i {}
+ lappend result [lsort [bind .t.f]]
}
return $result
} -cleanup {
@@ -385,7 +385,7 @@ test bind-10.2 {Tk_GetBinding procedure} -body {
test bind-11.1 {Tk_GetAllBindings procedure} -body {
frame .t.f
foreach i "! a \\\{ ~ <> <Â>" {
- bind .t.f $i Test
+ bind .t.f $i Test
}
lsort [bind .t.f]
} -cleanup {
@@ -394,7 +394,7 @@ test bind-11.1 {Tk_GetAllBindings procedure} -body {
test bind-11.2 {Tk_GetAllBindings procedure} -body {
frame .t.f
foreach i " " {
- bind .t.f $i Test
+ bind .t.f $i Test
}
lsort [bind .t.f]
} -cleanup {
@@ -403,7 +403,7 @@ test bind-11.2 {Tk_GetAllBindings procedure} -body {
test bind-11.3 {Tk_GetAllBindings procedure} -body {
frame .t.f
foreach i " abcd ab" {
- bind .t.f $i Test
+ bind .t.f $i Test
}
lsort [bind .t.f]
} -cleanup {
@@ -418,7 +418,7 @@ test bind-12.1 {Tk_DeleteAllBindings procedure} -body {
test bind-12.2 {Tk_DeleteAllBindings procedure} -body {
frame .t.f -class Test -width 150 -height 100
foreach i "a b c " {
- bind .t.f $i x
+ bind .t.f $i x
}
destroy .t.f
} -result {}
@@ -490,8 +490,8 @@ test bind-13.3 {Tk_BindEvent procedure} -setup {
(command bound to event)}}
test bind-13.4 {Tk_BindEvent procedure} -setup {
proc foo {} {
- set x 44
- event generate .t.f <:>
+ set x 44
+ event generate .t.f <:>
}
frame .t.f -class Test -width 150 -height 100
pack .t.f
@@ -936,7 +936,7 @@ test bind-13.33 {Tk_BindEvent procedure: many C bindings cause realloc} -setup {
} -body {
bindtags .t.f {a b c d e f g h i j k l m n o p}
foreach p [bindtags .t.f] {
- bind $p "lappend x $p"
+ bind $p "lappend x $p"
}
event generate .t.f
return $x
@@ -1019,8 +1019,8 @@ test bind-13.43 {Tk_BindEvent procedure: break in script} -setup {
} -result {b1}
test bind-13.45 {Tk_BindEvent procedure: error in script} -setup {
proc bgerror msg {
- global x
- lappend x $msg
+ global x
+ lappend x $msg
}
frame .t.f -class Test -width 150 -height 100
pack .t.f
@@ -6070,8 +6070,8 @@ test bind-28.15 {keysym names, Emoji} -body {
test bind-29.1 {Tcl_BackgroundError procedure} -setup {
proc bgerror msg {
- global x errorInfo
- set x [list $msg $errorInfo]
+ global x errorInfo
+ set x [list $msg $errorInfo]
}
frame .t.f -class Test -width 150 -height 100
pack .t.f
@@ -6094,12 +6094,12 @@ test bind-29.1 {Tcl_BackgroundError procedure} -setup {
test bind-29.2 {Tcl_BackgroundError procedure} -setup {
proc do {} {
- event generate .t.f