summaryrefslogtreecommitdiffstats
path: root/tests/font.test
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2022-10-11 20:13:03 (GMT)
committerfvogel <fvogelnew1@free.fr>2022-10-11 20:13:03 (GMT)
commit39b4a070af5ed074efb46594218092ddfa024ea7 (patch)
treea2f7ede0c0484d0cc909afb2f12bd89f8e0a843c /tests/font.test
parent5a64bed54b2c6a377a74941a0c09c4324c9cf878 (diff)
downloadtk-39b4a070af5ed074efb46594218092ddfa024ea7.zip
tk-39b4a070af5ed074efb46594218092ddfa024ea7.tar.gz
tk-39b4a070af5ed074efb46594218092ddfa024ea7.tar.bz2
Further try to avoid possible hangs in frame-12.3, textImage-4.2, font-47.2 and font-47.3. Hangs were (still) observed with frame-12.3 on macOS. This commit is based on an analysis of what is happening (from the events point of view) when changing a font configuration such as its size.
Diffstat (limited to 'tests/font.test')
-rw-r--r--tests/font.test10
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/font.test b/tests/font.test
index 25a1ea1..f292b58 100644
--- a/tests/font.test
+++ b/tests/font.test
@@ -2458,12 +2458,15 @@ test font-47.2 {Bug 3049518,TIP 608 - Canvas} -body {
set results {}
lappend results [apply $enclosed $c $circid]
font configure MyFont -size 26
- update
+ update idletasks ; # services the idle "TheWorldHasChanged" event, queues "TkWorldChanged" events
+ update ; # services the queued "TkWorldChanged" events
lappend results [apply $enclosed $c $circid]
font configure MyFont -size 9
+ update idletasks
update
lappend results [apply $enclosed $c $circid]
font configure MyFont -size 12
+ update idletasks
update
lappend results [apply $enclosed $c $circid]
} -cleanup {
@@ -2528,12 +2531,15 @@ test font-47.3 {Bug 3049518, TIP 608 - Label} -body {
apply $check $l
font configure MyFont -size 26
- update
+ update idletasks ; # services the idle "TheWorldHasChanged" event, queues "TkWorldChanged" events
+ update ; # services the queued "TkWorldChanged" events
apply $check $l
font configure MyFont -size 9
+ update idletasks
update
apply $check $l
font configure MyFont -size 13
+ update idletasks
update
apply $check $l
set results