summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/mac-build.yml8
-rw-r--r--generic/tkImgGIF.c6
-rw-r--r--generic/tkImgPNG.c26
-rw-r--r--generic/tkImgPhoto.c12
-rw-r--r--macosx/tkMacOSXMenu.c2
-rw-r--r--tests/clrpick.test4
-rw-r--r--tests/textDisp.test2
-rw-r--r--tests/unixWm.test12
-rw-r--r--tests/winWm.test3
-rw-r--r--tests/winfo.test2
-rw-r--r--tests/wm.test12
11 files changed, 44 insertions, 45 deletions
diff --git a/.github/workflows/mac-build.yml b/.github/workflows/mac-build.yml
index 51b6de6..a9a0c39 100644
--- a/.github/workflows/mac-build.yml
+++ b/.github/workflows/mac-build.yml
@@ -129,15 +129,11 @@ jobs:
: do nothing
}
fi
- ( runXvfb :0; make test-classic; exit $? ) | tee out-classic.txt || {
+ ( runXvfb :0; make test-classic test-ttk; exit $? ) | tee out.txt || {
echo "::error::Failure during Test"
exit 1
}
- ( runXvfb :0; make test-ttk; exit $? ) | tee out-ttk.txt || {
- echo "::error::Failure during Test"
- exit 1
- }
- cat out-classic.txt out-ttk.txt | grep -q "Failed[[:space:]][[:space:]]*[1-9]" && {
+ cat out.txt | grep -q "Failed [1-9]" && {
echo "::error::Failure during Test"
exit 1
}
diff --git a/generic/tkImgGIF.c b/generic/tkImgGIF.c
index 8702970..b9b5273 100644
--- a/generic/tkImgGIF.c
+++ b/generic/tkImgGIF.c
@@ -771,7 +771,7 @@ FileReadGIF(
result = TCL_OK;
error:
-
+
/*
* If a trash buffer has been allocated, free it now.
*/
@@ -1996,11 +1996,11 @@ CommonWriteGIF(
*/
if (NULL != metadataInObj) {
Tcl_Obj *itemData;
-
+
/*
* Check and code comment block
*/
-
+
if (TCL_ERROR == Tcl_DictObjGet(interp, metadataInObj,
Tcl_NewStringObj("comment",-1),
&itemData)) {
diff --git a/generic/tkImgPNG.c b/generic/tkImgPNG.c
index 5fd741c..69c2739 100644
--- a/generic/tkImgPNG.c
+++ b/generic/tkImgPNG.c
@@ -180,7 +180,7 @@ typedef struct {
/*
* Physical size: pHYS chunks.
*/
-
+
double DPI;
double aspect;
@@ -361,11 +361,11 @@ InitPNGImage(
}
return TCL_ERROR;
}
-
+
/*
* Initialize physical size pHYS values
*/
-
+
pngPtr->DPI = -1;
pngPtr->aspect = -1;
@@ -1710,7 +1710,7 @@ ReadPHYS(
* 4 bytes: Pixels per unit, y axis
* 1 byte: unit specifier
*/
-
+
if (ReadInt32(interp, pngPtr, &PPUx, &crc) == TCL_ERROR) {
return TCL_ERROR;
}
@@ -1724,7 +1724,7 @@ ReadPHYS(
if (CheckCRC(interp, pngPtr, crc) == TCL_ERROR) {
return TCL_ERROR;
}
-
+
if ( PPUx > 2147483647 || PPUy > 2147483647
|| unitSpecifier > 1 ) {
Tcl_SetObjResult(interp, Tcl_NewStringObj(
@@ -2520,7 +2520,7 @@ DecodePNG(
/*
* Physical header may be present here so try to parse it
*/
-
+
if (CHUNK_pHYs == chunkType) {
/*
* Finish parsing the PHYS chunk.
@@ -2593,7 +2593,7 @@ DecodePNG(
/*
* Physical header may be present here so try to parse it
*/
-
+
if (CHUNK_pHYs == chunkType) {
/*
* Finish parsing the PHYS chunk.
@@ -3509,7 +3509,7 @@ WriteExtraChunks(
return TCL_ERROR;
}
Tcl_DStringFree(&buf);
-
+
/*
* Add a pHYs chunk if there is metadata for DPI and/or aspect
* aspect = PPUy / PPUx
@@ -3519,14 +3519,14 @@ WriteExtraChunks(
* - Points per meter in x direction (32 bit)
* - Unit specifier: 0: no unit (only aspect), 1: Points per meter
*/
-
+
if (metadataInObj != NULL) {
-
+
Tcl_Obj *aspectObj, *DPIObj;
double aspectValue=-1, DPIValue=-1;
unsigned long PPUx = 65536, PPUy = 65536;
char unitSpecifier;
-
+
if (TCL_ERROR == Tcl_DictObjGet(interp, metadataInObj,
Tcl_NewStringObj("aspect",-1),
&aspectObj) ||
@@ -3555,7 +3555,7 @@ WriteExtraChunks(
/*
* aspect = PPUy / PPUx
*/
-
+
if (DPIObj == NULL) {
unitSpecifier = 0;
PPUx = 65536;
@@ -3573,7 +3573,7 @@ WriteExtraChunks(
Tcl_SetErrorCode(interp, "TK", "IMAGE", "PNG", "PHYS", NULL);
return TCL_ERROR;
}
-
+
LongToInt32(PPUx, buffer);
LongToInt32(PPUy, buffer+4);
buffer[8] = unitSpecifier;
diff --git a/generic/tkImgPhoto.c b/generic/tkImgPhoto.c
index 5352a15..cc4f412 100644
--- a/generic/tkImgPhoto.c
+++ b/generic/tkImgPhoto.c
@@ -799,11 +799,11 @@ ImgPhotoCmd(
options.format = Tcl_NewStringObj("default", -1);
freeObj = options.format;
}
-
+
/*
* Use argument metadata if specified, otherwise the master metadata
*/
-
+
if (NULL != options.metadata) {
metadataIn = options.metadata;
} else {
@@ -1468,11 +1468,11 @@ readCleanup:
usedExt = 0;
}
-
+
/*
* Use argument metadata if specified, otherwise the master metadata
*/
-
+
if (NULL != options.metadata) {
metadataIn = options.metadata;
} else {
@@ -2273,7 +2273,7 @@ ImgPhotoConfigureModel(
/*
* We have driver return metadata
*/
-
+
if (modelPtr->metadata == NULL) {
modelPtr->metadata = metadataOutObj;
metadataOutObj = NULL;
@@ -2880,7 +2880,7 @@ if (formatPtr == NULL) {
}
}
}
-
+
/*
* No matching format found
*/
diff --git a/macosx/tkMacOSXMenu.c b/macosx/tkMacOSXMenu.c
index 321d308..346ee47 100644
--- a/macosx/tkMacOSXMenu.c
+++ b/macosx/tkMacOSXMenu.c
@@ -198,7 +198,7 @@ TKBackgroundLoop *backgroundLoop = nil;
* accents over letters. But ⌘` is a standard KeyEquivalent which cycles
* through the open windows of an application, changing the focus to the next
* window.
- *
+ *
* The performKeyEquivalent callback method is being overridden here to work
* around a bug reported in [1626ed65b8]. When a dead key that is also as a
* KeyEquivalent is pressed, a KeyDown event with no characters is passed to
diff --git a/tests/clrpick.test b/tests/clrpick.test
index 13d43dc..84b883e 100644
--- a/tests/clrpick.test
+++ b/tests/clrpick.test
@@ -10,6 +10,8 @@ eval tcltest::configure $argv
tcltest::loadTestedCommands
namespace import -force tcltest::test
+testConstraint failsOnXQuarz [expr {$tcl_platform(os) ne "Darwin" || [tk windowingsystem] ne "x11" }]
+
if {[testConstraint defaultPseudocolor8]} {
# let's soak up a bunch of colors...so that
# machines with small color palettes still fail.
@@ -172,7 +174,7 @@ test clrpick-2.2 {tk_chooseColor command} -constraints {
tk_chooseColor -parent . -title "choose #808040"
} -result {#808040}
test clrpick-2.3 {tk_chooseColor command} -constraints {
- nonUnixUserInteraction colorsLeftover
+ nonUnixUserInteraction colorsLeftover failsOnXQuarz
} -body {
ToPressButton . ok
tk_chooseColor -parent . -title "Press OK"
diff --git a/tests/textDisp.test b/tests/textDisp.test
index d1296b4..a2e960f 100644
--- a/tests/textDisp.test
+++ b/tests/textDisp.test
@@ -3660,7 +3660,7 @@ test textDisp-27.6 {SizeOfTab procedure, center alignment} {textfonts} {
.t tag add x 1.0 end
list [.t bbox 1.6] [.t bbox 1.7]
} [list [list 32 [expr {$fixedDiff + 18}] 7 $fixedHeight] [list 39 [expr {$fixedDiff + 18}] 7 $fixedHeight]]
-test textDisp-27.7 {SizeOfTab procedure, center alignment, wrap -none (potential numerical problems)} {textfonts} {
+test textDisp-27.7 {SizeOfTab procedure, center alignment, wrap -none (potential numerical problems)} {textfonts failsOnXQuarz} {
.t delete 1.0 end
set cm [winfo fpixels .t 1c]
.t configure -tabs {1c 2c center 3c 4c 5c 6c 7c 8c} -wrap none -width 40
diff --git a/tests/unixWm.test b/tests/unixWm.test
index 9cb3ab6..2ff2d28 100644
--- a/tests/unixWm.test
+++ b/tests/unixWm.test
@@ -290,7 +290,7 @@ test unixWm-8.3 {icon windows} unix {
toplevel .t -width 100 -height 30
list [catch {wm iconwindow .t b c} msg] $msg
} {1 {wrong # args: should be "wm iconwindow window ?pathName?"}}
-test unixWm-8.4 {icon windows} {unix failsOnUbuntu} {
+test unixWm-8.4 {icon windows} {unix failsOnUbuntu failsOnXQuarz} {
destroy .t
destroy .icon
toplevel .t -width 100 -height 30
@@ -635,7 +635,7 @@ test unixWm-16.2 {Tk_WmCmd procedure, "deiconify" option} unix {
destroy .icon
set result
} {1 {can't deiconify .icon: it is an icon for .t}}
-test unixWm-16.3 {Tk_WmCmd procedure, "deiconify" option} {unix failsOnUbuntu} {
+test unixWm-16.3 {Tk_WmCmd procedure, "deiconify" option} {unix failsOnUbuntu failsOnXQuarz} {
wm iconify .t
set result {}
lappend result [winfo ismapped .t] [wm state .t]
@@ -854,7 +854,7 @@ test unixWm-23.4 {Tk_WmCmd procedure, "iconify" option} unix {
destroy .t2
set result
} {1 {can't iconify ".t2": it is an icon for ".t"}}
-test unixWm-23.5 {Tk_WmCmd procedure, "iconify" option} {unix failsOnUbuntu} {
+test unixWm-23.5 {Tk_WmCmd procedure, "iconify" option} {unix failsOnUbuntu failsOnXQuarz} {
destroy .t2
toplevel .t2
wm geom .t2 +0+0
@@ -865,7 +865,7 @@ test unixWm-23.5 {Tk_WmCmd procedure, "iconify" option} {unix failsOnUbuntu} {
destroy .t2
set result
} 0
-test unixWm-23.6 {Tk_WmCmd procedure, "iconify" option} {unix failsOnUbuntu} {
+test unixWm-23.6 {Tk_WmCmd procedure, "iconify" option} {unix failsOnUbuntu failsOnXQuarz} {
destroy .t2
toplevel .t2
wm geom .t2 -0+0
@@ -1436,7 +1436,7 @@ test unixWm-41.4 {ConfigureEvent procedure, synthesized Configure events} unix {
# No tests for ReparentEvent or ComputeReparentGeometry; I can't figure
# out how to exercise these procedures reliably.
-test unixWm-42.1 {WrapperEventProc procedure, map and unmap events} {unix failsOnUbuntu} {
+test unixWm-42.1 {WrapperEventProc procedure, map and unmap events} {unix failsOnUbuntu failsOnXQuarz} {
destroy .t
toplevel .t -width 400 -height 150
wm geometry .t +0+0
@@ -1960,7 +1960,7 @@ test unixWm-50.8 {Tk_CoordsToWindow procedure, more basics} unix {
[winfo containing [expr $x + 350] $y] \
[winfo containing [expr $x + 450] $y]
} {.t .t.f .t.f.f .t {}}
-test unixWm-50.9 {Tk_CoordsToWindow procedure, unmapped windows} {unix failsOnUbuntu} {
+test unixWm-50.9 {Tk_CoordsToWindow procedure, unmapped windows} {unix failsOnUbuntu failsOnXQuarz} {
destroy .t
destroy .t2
toplevel .t -width 200 -height 200 -bg green
diff --git a/tests/winWm.test b/tests/winWm.test
index 5246205..f659a13 100644
--- a/tests/winWm.test
+++ b/tests/winWm.test
@@ -15,6 +15,7 @@ tcltest::configure {*}$argv
tcltest::loadTestedCommands
testConstraint failsOnUbuntu [expr {![info exists ::env(CI)] || ![string match Linux $::tcl_platform(os)]}]
+testConstraint failsOnXQuarz [expr {$tcl_platform(os) ne "Darwin" || [tk windowingsystem] ne "x11" }]
test winWm-1.1 {TkWmMapWindow} -constraints win -setup {
destroy .t
@@ -533,7 +534,7 @@ test winWm-9.1 "delayed activation of grabbed destroyed window" -constraints win
destroy .tx .t .sd
} -result ok
-test winWm-9.2 "check wm forget for unmapped parent (#3205464,#2967911)" -constraints failsOnUbuntu -setup {
+test winWm-9.2 "check wm forget for unmapped parent (#3205464,#2967911)" -constraints {failsOnUbuntu failsOnXQuarz} -setup {
destroy .t
toplevel .t
set winwm92 {}
diff --git a/tests/winfo.test b/tests/winfo.test
index c9280cf..ae0af64 100644
--- a/tests/winfo.test
+++ b/tests/winfo.test
@@ -294,7 +294,7 @@ test winfo-9.2 {"winfo viewable" command} -body {
test winfo-9.3 {"winfo viewable" command} -body {
winfo viewable .
} -result 1
-test winfo-9.4 {"winfo viewable" command} -constraints failsOnUbuntu -body {
+test winfo-9.4 {"winfo viewable" command} -constraints {failsOnUbuntu failsOnXQuarz} -body {
wm iconify .
winfo viewable .
} -cleanup {
diff --git a/tests/wm.test b/tests/wm.test
index 6338c6b..e24181e 100644
--- a/tests/wm.test
+++ b/tests/wm.test
@@ -810,7 +810,7 @@ test wm-iconify-2.4.2 {Misc errors} -constraints !win -setup {
destroy .t2 .r.f
} -result {can't iconify ".t2": it is an embedded window}
-test wm-iconify-3.1 {iconify behavior} -constraints failsOnUbuntu -body {
+test wm-iconify-3.1 {iconify behavior} -constraints {failsOnUbuntu failsOnXQuarz} -body {
toplevel .t2
wm geom .t2 -0+0
update idletasks
@@ -1418,7 +1418,7 @@ test wm-stackorder-2.7 {stacking order: no children returns self} -setup {
deleteWindows
-test wm-stackorder-3.1 {unmapped toplevel} -constraints failsOnUbuntu -body {
+test wm-stackorder-3.1 {unmapped toplevel} -constraints {failsOnUbuntu failsOnXQuarz} -body {
toplevel .t1 ; update
toplevel .t2 ; update
wm iconify .t1
@@ -1739,7 +1739,7 @@ test wm-transient-4.1 {transient toplevel is withdrawn
deleteWindows
} -result {withdrawn 0}
test wm-transient-4.2 {already mapped transient toplevel
- is withdrawn if toplevel is iconic} -constraints failsOnUbuntu -body {
+ is withdrawn if toplevel is iconic} -constraints {failsOnUbuntu failsOnXQuarz} -body {
toplevel .top
raiseDelay
wm iconify .top
@@ -1753,7 +1753,7 @@ test wm-transient-4.2 {already mapped transient toplevel
deleteWindows
} -result {withdrawn 0}
test wm-transient-4.3 {iconify/deiconify on the toplevel
- does a withdraw/deiconify on the transient} -constraints failsOnUbuntu -setup {
+ does a withdraw/deiconify on the transient} -constraints {failsOnUbuntu failsOnXQuarz} -setup {
set results [list]
} -body {
toplevel .top
@@ -2006,7 +2006,7 @@ test wm-state-2.7 {state change before map} -body {
} -cleanup {
deleteWindows
} -result {iconic}
-test wm-state-2.8 {state change after map} -constraints failsOnUbuntu -body {
+test wm-state-2.8 {state change after map} -constraints {failsOnUbuntu failsOnXQuarz} -body {
toplevel .t
update
wm state .t iconic
@@ -2014,7 +2014,7 @@ test wm-state-2.8 {state change after map} -constraints failsOnUbuntu -body {
} -cleanup {
deleteWindows
} -result {iconic}
-test wm-state-2.9 {state change after map} -constraints failsOnUbuntu -body {
+test wm-state-2.9 {state change after map} -constraints {failsOnUbuntu failsOnXQuarz} -body {
toplevel .t
update
wm iconify .t