From e81cca9a1580b0ddae6685aa568a6b79a0796691 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Wed, 5 Jun 2019 14:46:29 +0000 Subject: Reduce the number of unnecessary end-of-line spacings --- generic/tkTest.c | 2 +- macosx/ttkMacOSXTheme.c | 10 +-- tests/clrpick.test | 2 +- tests/color.test | 2 +- tests/font.test | 172 ++++++++++++++++++++++++------------------------ tests/frame.test | 8 +-- tests/listbox.test | 8 +-- tests/pack.test | 2 +- tests/raise.test | 6 +- tests/unixFont.test | 6 +- tests/unixWm.test | 14 ++-- 11 files changed, 116 insertions(+), 116 deletions(-) diff --git a/generic/tkTest.c b/generic/tkTest.c index c1377d1..44fec0d 100644 --- a/generic/tkTest.c +++ b/generic/tkTest.c @@ -1552,7 +1552,7 @@ ImageDisplay( { TImageInstance *instPtr = (TImageInstance *) clientData; char buffer[200 + TCL_INTEGER_SPACE * 6]; - + /* * The purpose of the test image type is to track the calls to an image * display proc and record the parameters passed in each call. On macOS diff --git a/macosx/ttkMacOSXTheme.c b/macosx/ttkMacOSXTheme.c index d8af0cb..c33e8c9 100644 --- a/macosx/ttkMacOSXTheme.c +++ b/macosx/ttkMacOSXTheme.c @@ -79,10 +79,10 @@ static CGFloat darkFocusRing[4] = { 38.0 / 255, 113.0 / 255, 159.0 / 255, 1.0 }; static CGFloat darkFocusRingTop[4] = { - 50.0 / 255, 124.0 / 255, 171.0 / 255, 1.0 + 50.0 / 255, 124.0 / 255, 171.0 / 255, 1.0 }; static CGFloat darkFocusRingBottom[4] = { - 57.0 / 255, 130.0 / 255, 176.0 / 255, 1.0 + 57.0 / 255, 130.0 / 255, 176.0 / 255, 1.0 }; static CGFloat darkTabSeparator[4] = {0.0, 0.0, 0.0, 0.25}; static CGFloat darkTrack[4] = {1.0, 1.0, 1.0, 0.25}; @@ -1043,7 +1043,7 @@ static void DrawDarkFocusRing( }; CGPoint bottom[2] = {{x, y + h}, {x + w, y + h}}; CGRect outerRect = CGRectInset(bounds, -3, -3); - + CGContextSaveGState(context); CGContextSetShouldAntialias(context, false); CGContextBeginPath(context); @@ -1693,11 +1693,11 @@ static void EntryElementDraw( NSColorSpace *deviceRGB = [NSColorSpace deviceRGBColorSpace]; CGFloat fill[4]; GetBackgroundColor(dc.context, tkwin, 1, fill); - + /* * Lighten the background to provide contrast. */ - + for (int i = 0; i < 3; i++) { fill[i] += 9.0 / 255.0; } diff --git a/tests/clrpick.test b/tests/clrpick.test index 5f1b8b5..c15308b 100644 --- a/tests/clrpick.test +++ b/tests/clrpick.test @@ -78,7 +78,7 @@ test clrpick-1.7 {tk_chooseColor command} -body { # tests 3.1 and 3.2 fail when individually run # if there is no catch {tk_chooseColor -foo 1} msg # before settin isNative -catch {tk_chooseColor -foo 1} msg +catch {tk_chooseColor -foo 1} msg set isNative [expr {[info commands tk::dialog::color::] eq ""}] proc ToPressButton {parent btn} { diff --git a/tests/color.test b/tests/color.test index 6fefd90..4cdaf23 100644 --- a/tests/color.test +++ b/tests/color.test @@ -168,7 +168,7 @@ test color-1.5 {Color table} nonPortable { if {$rgb != [lrange $line 0 2] } { append result $line\n } - + } return $result } {} diff --git a/tests/font.test b/tests/font.test index f7fb325..8894d85 100644 --- a/tests/font.test +++ b/tests/font.test @@ -109,7 +109,7 @@ test font-4.1 {font command: actual: arguments} -body { font actual xyz -displayof } -returnCodes error -result {value for "-displayof" missing} test font-4.2 {font command: actual: arguments} -body { - # (objc < 3) + # (objc < 3) font actual } -returnCodes error -result {wrong # args: should be "font actual font ?-displayof window? ?option? ?--? ?char?"} test font-4.3 {font command: actual: arguments} -body { @@ -160,7 +160,7 @@ test font-4.15 {font command: actual} -body { test font-5.1 {font command: configure} -body { - # (objc < 3) + # (objc < 3) font configure } -returnCodes error -result {wrong # args: should be "font configure fontname ?-option value ...?"} test font-5.2 {font command: configure: non-existent font} -body { @@ -173,7 +173,7 @@ test font-5.3 {font command: configure: "deleted" font} -setup { pack [label .t.f] update } -body { - # (nfPtr->deletePending != 0) + # (nfPtr->deletePending != 0) font create xyz .t.f configure -font xyz font delete xyz @@ -263,13 +263,13 @@ test font-6.4 {font command: create: generate name} -setup { test font-6.5 {font command: create: bad option creating new font} -setup { catch {font delete xyz} } -body { - # name was specified so skip = 3 + # name was specified so skip = 3 font create xyz -xyz times } -returnCodes error -result {bad option "-xyz": must be -family, -size, -weight, -slant, -underline, or -overstrike} test font-6.6 {font command: create: bad option creating new font} -setup { clearnondefaultfonts } -body { - # name was not specified so skip = 2 + # name was not specified so skip = 2 font create -xyz times } -returnCodes error -result {bad option "-xyz": must be -family, -size, -weight, -slant, -underline, or -overstrike} test font-6.7 {font command: create: already exists} -setup { @@ -283,14 +283,14 @@ test font-6.7 {font command: create: already exists} -setup { } -returnCodes error -result {named font "xyz" already exists} test font-7.1 {font command: delete: arguments} -body { - # (objc < 3) + # (objc < 3) font delete } -returnCodes error -result {wrong # args: should be "font delete fontname ?fontname ...?"} test font-7.2 {font command: delete: loop test} -setup { clearnondefaultfonts set x {} } -body { - # for (i = 2; i < objc; i++) + # for (i = 2; i < objc; i++) font create a -underline 1 font create b -underline 1 font create c -underline 1 @@ -321,7 +321,7 @@ test font-7.3 {font command: delete: loop test} -setup { test font-7.4 {font command: delete: non-existent} -setup { catch {font delete xyz} } -body { - # (namedHashPtr == NULL) + # (namedHashPtr == NULL) font delete xyz } -returnCodes error -result {named font "xyz" doesn't exist} test font-7.5 {font command: delete: mark for later deletion} -setup { @@ -388,11 +388,11 @@ test font-9.1 {font command: measure: arguments} -body { expr {[font measure xyz -displayof] > 0} } -returnCodes ok -result 1 test font-9.2 {font command: measure: arguments} -body { - # (objc - skip != 4) + # (objc - skip != 4) font measure } -returnCodes error -result {wrong # args: should be "font measure font ?-displayof window? text"} test font-9.3 {font command: measure: arguments} -body { - # (objc - skip != 4) + # (objc - skip != 4) font measure xyz abc def } -returnCodes error -result {wrong # args: should be "font measure font ?-displayof window? text"} test font-9.4 {font command: measure: arguments} -constraints noExceed -body { @@ -422,7 +422,7 @@ test font-10.2 {font command: metrics: arguments} -body { font metrics xyz -displayof } -returnCodes error -result {value for "-displayof" missing} test font-10.3 {font command: metrics: arguments} -body { - # (objc < 3) + # (objc < 3) font metrics } -returnCodes error -result {wrong # args: should be "font metrics font ?-displayof window? ?option?"} test font-10.4 {font command: metrics: arguments} -body { @@ -585,7 +585,7 @@ test font-14.1 {Tk_GetFont procedure} -body { test font-15.1 {Tk_AllocFontFromObj - converting internal reps} -constraints { - testfont + testfont } -setup { destroy .b1 .b2 } -body { @@ -598,7 +598,7 @@ test font-15.1 {Tk_AllocFontFromObj - converting internal reps} -constraints { destroy .b1 .b2 } -result {{1 0}} test font-15.2 {Tk_AllocFontFromObj - discard stale font} -constraints { - testfont + testfont } -setup { destroy .b1 .b2 set result {} @@ -613,7 +613,7 @@ test font-15.2 {Tk_AllocFontFromObj - discard stale font} -constraints { destroy .b2 } -result {{} {{1 1}}} test font-15.3 {Tk_AllocFontFromObj - reuse existing font} -constraints { - testfont + testfont } -setup { destroy .b1 .b2 set result {} @@ -644,9 +644,9 @@ test font-15.5 {Tk_AllocFontFromObj procedure: get named font} -setup { pack [label .t.f] update } -body { - # (namedHashPtr != NULL) - font create xyz - .t.f config -font xyz + # (namedHashPtr != NULL) + font create xyz + .t.f config -font xyz } -cleanup { destroy .t.f font delete xyz @@ -662,24 +662,24 @@ test font-15.6 {Tk_AllocFontFromObj procedure: not a named font} -setup { destroy .t.f } -result {-family} -result {} test font-15.7 {Tk_AllocFontFromObj procedure: get native font} -constraints { - unix + unix } -setup { destroy .t.f pack [label .t.f] update } -body { - # not (fontPtr == NULL) + # not (fontPtr == NULL) .t.f config -font fixed } -result {} test font-15.8 {Tk_AllocFontFromObj procedure: get native font} -constraints { - win + win } -setup { destroy .t.f clearnondefaultfonts pack [label .t.f] update } -body { - # not (fontPtr == NULL) + # not (fontPtr == NULL) .t.f config -font oemfixed } -cleanup { destroy .t.f @@ -689,7 +689,7 @@ test font-15.9 {Tk_AllocFontFromObj procedure: get attribute font} -setup { pack [label .t.f] update } -body { - # (fontPtr == NULL) + # (fontPtr == NULL) .t.f config -font {xxx yyy zzz} } -cleanup { destroy .t.f @@ -724,7 +724,7 @@ test font-15.13 {Tk_AllocFontFromObj procedure: underline position} -setup { update } -cleanup { destroy .t.f -} -result {} +} -result {} test font-16.1 {Tk_NameOfFont procedure} -setup { @@ -740,7 +740,7 @@ test font-16.1 {Tk_NameOfFont procedure} -setup { test font-17.1 {Tk_FreeFontFromObj - reference counts} -constraints { - testfont + testfont } -setup { destroy .b1 .b2 .b3 set result {} @@ -785,7 +785,7 @@ test font-17.4 {Tk_FreeFont procedure: named font} -setup { pack [label .t.f] update } -body { - # (fontPtr->namedHashPtr != NULL) + # (fontPtr->namedHashPtr != NULL) font create xyz .t.f config -font xyz destroy .t.f @@ -797,7 +797,7 @@ test font-17.5 {Tk_FreeFont procedure: named font} -setup { pack [label .t.f] update } -body { - # not (fontPtr->refCount == 0) + # not (fontPtr->refCount == 0) font create xyz -underline 1 .t.f config -font xyz font delete xyz @@ -811,7 +811,7 @@ test font-17.6 {Tk_FreeFont procedure: named font not deleted yet} -setup { pack [label .t.f] update } -body { - font create xyz + font create xyz .t.f config -font xyz button .t.b -font xyz font delete xyz @@ -870,7 +870,7 @@ test font-20.1 {Tk_GetFontMetrics procedure} -setup { # Procedure used in 21.* tests proc psfontname {name} { destroy .t.c - canvas .t.c -closeenough 0 + canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -896,22 +896,22 @@ test font-21.1 {Tk_PostscriptFontName procedure: native} -constraints { } } -result {AvantGarde-Book} test font-21.2 {Tk_PostscriptFontName procedure: native} -constraints { - win + win } -body { psfontname "arial 10" } -result {Helvetica} test font-21.3 {Tk_PostscriptFontName procedure: native} -constraints { - win + win } -body { psfontname "{times new roman} 10" } -result {Times-Roman} test font-21.4 {Tk_PostscriptFontName procedure: native} -constraints { - win + win } -body { psfontname "{courier new} 10" } -result {Courier} test font-21.5 {Tk_PostscriptFontName procedure: spaces} -constraints { - unix + unix } -body { set x [font actual {{lucida bright} 10} -family] if {[string match lucida*bright $x]} { @@ -921,13 +921,13 @@ test font-21.5 {Tk_PostscriptFontName procedure: spaces} -constraints { } } -result {LucidaBright} test font-21.6 {Tk_PostscriptFontName procedure: spaces} -constraints { - x11 + x11 } -body { psfontname "{new century schoolbook} 10" } -result {NewCenturySchlbk-Roman} test font-21.7 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {avantgarde 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "avantgarde"} { @@ -937,7 +937,7 @@ test font-21.7 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {AvantGarde-Book} test font-21.8 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {avantgarde 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "avantgarde"} { @@ -947,7 +947,7 @@ test font-21.8 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {AvantGarde-Demi} test font-21.9 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {avantgarde 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "avantgarde"} { @@ -957,7 +957,7 @@ test font-21.9 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {AvantGarde-BookOblique} test font-21.10 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {avantgarde 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "avantgarde"} { @@ -968,7 +968,7 @@ test font-21.10 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {AvantGarde-DemiOblique} test font-21.11 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {bookman 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "bookman"} { @@ -978,7 +978,7 @@ test font-21.11 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Bookman-Light} test font-21.12 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {bookman 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "bookman"} { @@ -988,7 +988,7 @@ test font-21.12 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Bookman-Demi} test font-21.13 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {bookman 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "bookman"} { @@ -998,7 +998,7 @@ test font-21.13 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Bookman-LightItalic} test font-21.14 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {bookman 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "bookman"} { @@ -1009,7 +1009,7 @@ test font-21.14 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Bookman-DemiItalic} test font-21.15 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {courier 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "courier"} { @@ -1019,7 +1019,7 @@ test font-21.15 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Courier} test font-21.16 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {courier 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "courier"} { @@ -1029,7 +1029,7 @@ test font-21.16 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Courier-Bold} test font-21.17 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {courier 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "courier"} { @@ -1039,7 +1039,7 @@ test font-21.17 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Courier-Oblique} test font-21.18 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {courier 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "courier"} { @@ -1050,7 +1050,7 @@ test font-21.18 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Courier-BoldOblique} test font-21.19 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {helvetica 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "helvetica"} { @@ -1060,7 +1060,7 @@ test font-21.19 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Helvetica} test font-21.20 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {helvetica 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "helvetica"} { @@ -1070,7 +1070,7 @@ test font-21.20 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Helvetica-Bold} test font-21.21 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {helvetica 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "helvetica"} { @@ -1080,7 +1080,7 @@ test font-21.21 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Helvetica-Oblique} test font-21.22 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {helvetica 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "helvetica"} { @@ -1091,7 +1091,7 @@ test font-21.22 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Helvetica-BoldOblique} test font-21.23 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {{new century schoolbook} 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "new century schoolbook"} { @@ -1101,7 +1101,7 @@ test font-21.23 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {NewCenturySchlbk-Roman} test font-21.24 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {{new century schoolbook} 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "new century schoolbook"} { @@ -1111,7 +1111,7 @@ test font-21.24 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {NewCenturySchlbk-Bold} test font-21.25 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {{new century schoolbook} 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "new century schoolbook"} { @@ -1121,7 +1121,7 @@ test font-21.25 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {NewCenturySchlbk-Italic} test font-21.26 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {{new century schoolbook} 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "new century schoolbook"} { @@ -1132,7 +1132,7 @@ test font-21.26 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {NewCenturySchlbk-BoldItalic} test font-21.27 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {palatino 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "palatino"} { @@ -1142,7 +1142,7 @@ test font-21.27 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Palatino-Roman} test font-21.28 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {palatino 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "palatino"} { @@ -1152,7 +1152,7 @@ test font-21.28 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Palatino-Bold} test font-21.29 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {palatino 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "palatino"} { @@ -1162,7 +1162,7 @@ test font-21.29 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Palatino-Italic} test font-21.30 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {palatino 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "palatino"} { @@ -1173,7 +1173,7 @@ test font-21.30 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Palatino-BoldItalic} test font-21.31 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {symbol 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "symbol"} { @@ -1183,7 +1183,7 @@ test font-21.31 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Symbol} test font-21.32 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {symbol 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "symbol"} { @@ -1193,7 +1193,7 @@ test font-21.32 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Symbol} test font-21.33 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {symbol 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "symbol"} { @@ -1203,7 +1203,7 @@ test font-21.33 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Symbol} test font-21.34 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {symbol 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "symbol"} { @@ -1214,7 +1214,7 @@ test font-21.34 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Symbol} test font-21.35 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {times 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "times"} { @@ -1224,7 +1224,7 @@ test font-21.35 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Times-Roman} test font-21.36 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {times 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "times"} { @@ -1234,7 +1234,7 @@ test font-21.36 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Times-Bold} test font-21.37 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {times 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "times"} { @@ -1244,7 +1244,7 @@ test font-21.37 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {Times-Italic} test font-21.38 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {times 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "times"} { @@ -1255,7 +1255,7 @@ test font-21.38 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {Times-BoldItalic} test font-21.39 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfchancery 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "zapfchancery"} { @@ -1265,7 +1265,7 @@ test font-21.39 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfChancery-MediumItalic} test font-21.40 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfchancery 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "zapfchancery"} { @@ -1275,7 +1275,7 @@ test font-21.40 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfChancery-MediumItalic} test font-21.41 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfchancery 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "zapfchancery"} { @@ -1285,7 +1285,7 @@ test font-21.41 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfChancery-MediumItalic} test font-21.42 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfchancery 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "zapfchancery"} { @@ -1296,7 +1296,7 @@ test font-21.42 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } -result {ZapfChancery-MediumItalic} test font-21.43 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfdingbats 12 roman normal} if {[font actual {avantgarde 12 roman normal} -family] == "zapfdingbats"} { @@ -1306,7 +1306,7 @@ test font-21.43 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfDingbats} test font-21.44 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfdingbats 12 roman bold} if {[font actual {avantgarde 12 roman normal} -family] == "zapfdingbats"} { @@ -1316,7 +1316,7 @@ test font-21.44 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfDingbats} test font-21.45 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfdingbats 12 italic normal} if {[font actual {avantgarde 12 roman normal} -family] == "zapfdingbats"} { @@ -1326,7 +1326,7 @@ test font-21.45 {Tk_PostscriptFontName procedure: exhaustive} -constraints { } } -result {ZapfDingbats} test font-21.46 {Tk_PostscriptFontName procedure: exhaustive} -constraints { - unix + unix } -body { set name {zapfdingbats 12 italic bold} if {[font actual {avantgarde 12 roman normal} -family] == "zapfdingbats"} { @@ -1443,7 +1443,7 @@ test font-21.66 {Tk_PostscriptFontName procedure: exhaustive} -constraints { test font-22.1 {Tk_TextWidth procedure} -setup { - destroy .t.l + destroy .t.l } -body { label .t.l -padx 0 -pady 0 -bd 0 -highlightthickness 0 -justify left \ -text "0" -font "Courier -12" @@ -1469,7 +1469,7 @@ test font-23.1 {Tk_UnderlineChars procedure} -setup { # Data used in 24.* tests -destroy .t.l +destroy .t.l label .t.l -padx 0 -pady 0 -bd 0 -highlightthickness 0 -justify left \ -text "0" -font "Courier -12" pack .t.l @@ -1594,12 +1594,12 @@ test font-24.14 {Tk_ComputeTextLayout: text ended with \n} -body { lappend x [expr {[winfo reqheight .t.l] eq [expr {$ay * 2}]}] return $x } -result {1 1 1 1} -destroy .t.l +destroy .t.l test font-24.15 {Tk_ComputeTextLayout: justification} -setup { set x {} destroy .t.c - canvas .t.c -closeenough 0 + canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1628,11 +1628,11 @@ test font-25.1 {Tk_FreeTextLayout procedure} -setup { } -cleanup { destroy .t.f } -result {} - + # Canvas created for tests: 26.* destroy .t.c -canvas .t.c -closeenough 0 +canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1690,7 +1690,7 @@ destroy .t.f # Canvas created for tests: 28.* destroy .t.c -canvas .t.c -closeenough 0 +canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1782,7 +1782,7 @@ destroy .t.f # Canvas created for tests: 30.* destroy .t.c -canvas .t.c -closeenough 0 +canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1925,7 +1925,7 @@ destroy .t.c # Canvas created for tests 31.* destroy .t.c -canvas .t.c -closeenough 0 +canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1971,7 +1971,7 @@ destroy .t.c test font-32.1 {Tk_TextLayoutToPostscript: ensure buffer doesn't overflow} -setup { destroy .t.c - canvas .t.c -closeenough 0 + canvas .t.c -closeenough 0 .t.c create text 0 0 -tags text -anchor nw -just left -font "Courier -12" pack .t.c update @@ -1984,7 +1984,7 @@ test font-32.1 {Tk_TextLayoutToPostscript: ensure buffer doesn't overflow} -setu .t.c insert text end "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" .t.c insert text end "end" set x [.t.c postscript] - set i [string first "(qwerty" $x] + set i [string first "(qwerty" $x] string range $x $i [expr {$i + 278}] } -cleanup { destroy .t.c @@ -2200,7 +2200,7 @@ test font-37.6 {GetAttributeInfo procedure: underline} -setup { set x {} } -body { font create xyz -underline yes - font config xyz -underline + font config xyz -underline } -cleanup { font delete xyz } -result {1} @@ -2209,7 +2209,7 @@ test font-37.7 {GetAttributeInfo procedure: overstrike} -setup { set x {} } -body { font create xyz -overstrike no - font config xyz -overstrike + font config xyz -overstrike } -cleanup { font delete xyz } -result {0} diff --git a/tests/frame.test b/tests/frame.test index e374326..fe38128 100644 --- a/tests/frame.test +++ b/tests/frame.test @@ -60,7 +60,7 @@ test frame-1.1 {frame configuration options} -setup { .f configure -class } -cleanup { deleteWindows -} -result {-class class Class Frame NewFrame} +} -result {-class class Class Frame NewFrame} test frame-1.2 {frame configuration options} -setup { deleteWindows } -body { @@ -800,7 +800,7 @@ test frame-3.18 {TkCreateFrame procedure} -constraints { } -setup { deleteWindows } -body { - toplevel .t -visual {grayscale 8} -width 300 -height 200 -bg #434343 + toplevel .t -visual {grayscale 8} -width 300 -height 200 -bg #434343 wm geometry .t +0+0 update colorsFree .t 131 131 131 @@ -844,7 +844,7 @@ test frame-3.21 {TkCreateFrame procedure} -constraints { deleteWindows } -body { set x ok - toplevel .t -visual {grayscale 8} -width 300 -height 200 -bg #434343 + toplevel .t -visual {grayscale 8} -width 300 -height 200 -bg #434343 wm geometry .t +0+0 update colorsFree .t 131 131 131 @@ -1140,7 +1140,7 @@ test frame-12.2 {FrameWorldChanged procedure} -setup { place .f -x 0 -y 0 -width 100 -height 100 pack [frame .f.f] -fill both -expand 1 - set result {} + set result {} foreach lp {nw n ne en e es se s sw ws w wn} { .f configure -labelanchor $lp update diff --git a/tests/listbox.test b/tests/listbox.test index 2c07633..68cb5d8 100644 --- a/tests/listbox.test +++ b/tests/listbox.test @@ -1404,7 +1404,7 @@ test listbox-4.12 {ConfigureListbox procedure, listvar -> different listvar} -se } -body { set x [list a b c d] set y [list 1 2 3 4] - listbox .l2 + listbox .l2 .l2 configure -listvar x .l2 configure -listvar y .l2 insert end 5 6 7 8 @@ -1552,7 +1552,7 @@ test listbox-5.6 {ListboxComputeGeometry procedure} -setup { } -cleanup { destroy .l } -result {} - + # Listbox used in 6.*, 7.* tests destroy .l @@ -1913,7 +1913,7 @@ test listbox-9.1 {ListboxCmdDeletedProc procedure} -setup { deleteWindows } -result {{} {}} test listbox-9.2 {ListboxCmdDeletedProc procedure, disabling -setgrid} -constraints { - fonts + fonts } -setup { destroy .top } -body { @@ -2994,7 +2994,7 @@ test listbox-25.2 {listbox item configurations and widget based inserts} -setup } -cleanup { destroy .l } -result {{} red} - + # state issues test listbox-26.1 {listbox disabled state disallows inserts} -setup { diff --git a/tests/pack.test b/tests/pack.test index e2efb4d..b1c22c7 100644 --- a/tests/pack.test +++ b/tests/pack.test @@ -1562,7 +1562,7 @@ test pack-18.1 {unmap slaves when master unmapped} -constraints { wm geometry .pack +100+100 - # On the PC, when the width/height is configured while the window is + # On the PC, when the width/height is configured while the window is # unmapped, the changes don't take effect until the window is remapped. # Who knows why? diff --git a/tests/raise.test b/tests/raise.test index 461ccbf..f8674fc 100644 --- a/tests/raise.test +++ b/tests/raise.test @@ -131,7 +131,7 @@ test raise-3.1 {raise internal windows after creation} -body { raise_getOrder } -result {a d d a c e e e} test raise-3.2 {raise internal windows after creation} -constraints { - testmakeexist + testmakeexist } -body { raise_setup testmakeexist .raise.a .raise.b @@ -140,7 +140,7 @@ test raise-3.2 {raise internal windows after creation} -constraints { raise_getOrder } -result {d d d a c e e e} test raise-3.3 {raise internal windows after creation} -constraints { - testmakeexist + testmakeexist } -body { raise_setup testmakeexist .raise.a .raise.d @@ -149,7 +149,7 @@ test raise-3.3 {raise internal windows after creation} -constraints { raise_getOrder } -result {d d d a c e e e} test raise-3.4 {raise internal windows after creation} -constraints { - testmakeexist + testmakeexist } -body { raise_setup testmakeexist .raise.a .raise.c .raise.d diff --git a/tests/unixFont.test b/tests/unixFont.test index a4dbaa5..177dab5 100644 --- a/tests/unixFont.test +++ b/tests/unixFont.test @@ -1,4 +1,4 @@ -# This file is a Tcl script to test out the procedures in tkUnixFont.c. +# This file is a Tcl script to test out the procedures in tkUnixFont.c. # It is organized in the standard fashion for Tcl tests. # # Many of these tests are visually oriented and cannot be checked @@ -6,7 +6,7 @@ # underlined?"); these tests attempt to exercise the code in question, # but there are no results that can be checked. Some tests depend on the # fonts having or not having certain properties, which may not be valid -# at all sites. +# at all sites. # # Copyright (c) 1996 Sun Microsystems, Inc. # Copyright (c) 1998-1999 by Scriptics Corporation. @@ -124,7 +124,7 @@ test unixfont-2.11 {TkpGetFontFromAttributes: font cannot be loaded} x11 { font actual {-size 14} set x {} -} {} +} {} test unixfont-3.1 {TkpDeleteFont procedure} x11 { font actual {-family xyz} diff --git a/tests/unixWm.test b/tests/unixWm.test index c147bbf..28c8159 100644 --- a/tests/unixWm.test +++ b/tests/unixWm.test @@ -658,7 +658,7 @@ test unixWm-17.2 {Tk_WmCmd procedure, "focusmodel" option} unix { list [catch {wm focusmodel .t bogus} msg] $msg } {1 {bad argument "bogus": must be active or passive}} test unixWm-17.3 {Tk_WmCmd procedure, "focusmodel" option} unix { - set result {} + set result {} lappend result [wm focusmodel .t] wm focusmodel .t active lappend result [wm focusmodel .t] @@ -824,7 +824,7 @@ test unixWm-22.2 {Tk_WmCmd procedure, "iconbitmap" option} {unix testwrapper} { lappend result [wm iconbitmap .t] $bit } {{} questhead 0x4 {} 0x0} if {[tk windowingsystem] == "aqua"} { - set result_22_3 {0 {}} + set result_22_3 {0 {}} } else { set result_22_3 {1 {bitmap "bad-bitmap" not defined}} } @@ -1364,7 +1364,7 @@ test unixWm-40.1 {Tk_SetGrid procedure, set grid dimensions before turning on gr destroy .t toplevel .t wm geometry .t 30x10+0+0 - listbox .t.l -height 20 -width 20 -setgrid 1 + listbox .t.l -height 20 -width 20 -setgrid 1 pack .t.l -fill both -expand 1 update wm geometry .t @@ -1373,7 +1373,7 @@ test unixWm-40.2 {Tk_SetGrid procedure, turning on grid when dimensions already destroy .t toplevel .t wm geometry .t 200x100+0+$Y0 - listbox .t.l -height 20 -width 20 + listbox .t.l -height 20 -width 20 pack .t.l -fill both -expand 1 update .t.l configure -setgrid 1 @@ -1790,14 +1790,14 @@ test unixWm-49.2 {Tk_GetRootCoords procedure, menubars} {unix testmenubar} { testmenubar window .t .t.m update list [expr [winfo rootx .t.m.f] - $x] [expr [winfo rooty .t.m.f] - $y] \ - [expr [winfo rootx .t.f] - $x] [expr [winfo rooty .t.f] - $y] + [expr [winfo rootx .t.f] - $x] [expr [winfo rooty .t.f] - $y] } {52 7 12 62} deleteWindows wm withdraw . if {[tk windowingsystem] == "aqua"} { # Modern mac windows have no border. - set result_50_1 {{} {} .t .t .t2 {} .t2 .t .t} + set result_50_1 {{} {} .t .t .t2 {} .t2 .t .t} } else { # Windows are assumed to have a border (invisible in Gnome 3). set result_50_1 {{} {} .t {} .t2 {} .t2 {} .t} @@ -1851,7 +1851,7 @@ test unixWm-50.3 { } tempNotWin { deleteWindows catch {interp delete slave} - + toplevel .t -width 300 -height 400 -bg blue wm geom .t +100+100 frame .t.f -container 1 -bg red -- cgit v0.12