summaryrefslogtreecommitdiffstats
path: root/tests/textDisp.test
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2021-06-24 21:29:33 (GMT)
committerfvogel <fvogelnew1@free.fr>2021-06-24 21:29:33 (GMT)
commita02de41bf10af7d71d34b4a89620d38ecb6528d8 (patch)
treee105e93b48fefaabd973167b86dfffa7f5c11b1c /tests/textDisp.test
parent8ce7ec692df85c028153e7d99179f33a68016902 (diff)
downloadtk-a02de41bf10af7d71d34b4a89620d38ecb6528d8.zip
tk-a02de41bf10af7d71d34b4a89620d38ecb6528d8.tar.gz
tk-a02de41bf10af7d71d34b4a89620d38ecb6528d8.tar.bz2
Remove variables used only once.
Diffstat (limited to 'tests/textDisp.test')
-rw-r--r--tests/textDisp.test14
1 files changed, 6 insertions, 8 deletions
diff --git a/tests/textDisp.test b/tests/textDisp.test
index 42d802f..51f0314 100644
--- a/tests/textDisp.test
+++ b/tests/textDisp.test
@@ -63,14 +63,11 @@ proc lequal {res expected} {
}
# Create entries in the option database to be sure that geometry options
-# like border width have predictable values.
-set twbw 2
-set twht 2
-set pad 1
-option add *Text.borderWidth $twbw
-option add *Text.highlightThickness $twht
-option add *Text.padX $pad ; # same padding in x and y, see proc bo
-option add *Text.padY $pad ; # same padding in x and y, see proc bo
+# like border width have selected values.
+option add *Text.borderWidth 2
+option add *Text.highlightThickness 2
+option add *Text.padX 1 ; # same padding in x and y, see proc bo
+option add *Text.padY 1 ; # same padding in x and y, see proc bo
# The frame .f is needed to make sure that the overall window is always
# fairly wide, even if the text window is very narrow. This is needed
@@ -89,6 +86,7 @@ set fixedAscent [font metrics $fixedFont -ascent]
set bigFont {Helvetica -24} ; # note: not a fixed-width font!
set bigHeight [font metrics $bigFont -linespace]
set bigAscent [font metrics $bigFont -ascent]
+
set ascentDiff [expr {$bigAscent - $fixedAscent}]
set heightDiff [expr {$bigHeight - $fixedHeight}]