summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2015-07-28 22:17:23 (GMT)
committerfvogel <fvogelnew1@free.fr>2015-07-28 22:17:23 (GMT)
commit5da8b2cf18ec7d214d94b627b90307d055afd46f (patch)
treea4eec7d968b64156abbeb7024fb91385fec5d583 /tests
parentf286e06ad2da094e8154ec23f9b379d5cadd4f2d (diff)
downloadtk-5da8b2cf18ec7d214d94b627b90307d055afd46f.zip
tk-5da8b2cf18ec7d214d94b627b90307d055afd46f.tar.gz
tk-5da8b2cf18ec7d214d94b627b90307d055afd46f.tar.bz2
Made textDisp-4.9 more robust to font variations across platforms, so that it passes on Linux Debian 6.0
Diffstat (limited to 'tests')
-rw-r--r--tests/textDisp.test6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/textDisp.test b/tests/textDisp.test
index dbfeb95..a6bbfd7 100644
--- a/tests/textDisp.test
+++ b/tests/textDisp.test
@@ -615,6 +615,10 @@ catch {destroy .f2}
.t configure -borderwidth 0 -wrap char
wm geom . {}
update
+set bw [.t cget -borderwidth]
+set px [.t cget -padx]
+set py [.t cget -pady]
+set hlth [.t cget -highlightthickness]
test textDisp-4.7 {UpdateDisplayInfo, filling in extra vertical space} {
# This test was failing on Windows because the title bar on .
# was a certain minimum size and it was interfering with the size
@@ -653,7 +657,7 @@ test textDisp-4.9 {UpdateDisplayInfo, filling in extra vertical space} {textfont
update
.t delete 15.0 end
list [.t bbox 7.0] [.t bbox 12.0]
-} [list [list 3 [expr {2*$fixedDiff + 14}] 7 $fixedHeight] [list 3 [expr {7*$fixedDiff + 79}] 7 $fixedHeight]]
+} [list [list [expr {$hlth + $px + $bw}] [expr {$hlth + $py + $bw + $fixedHeight}] $fixedWidth $fixedHeight] [list [expr {$hlth + $px + $bw}] [expr {$hlth + $py + $bw + 6 * $fixedHeight}] $fixedWidth $fixedHeight]]
test textDisp-4.10 {UpdateDisplayInfo, filling in extra vertical space} {
.t delete 1.0 end
.t insert end "1\n2\n3\n4\n5\nLine 6 is such a long line that it wraps around.\n7\n8\n9\n10\n11\n12\n13\n14\n15\n16\n17"