summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorhobbs <hobbs>2001-11-17 22:44:04 (GMT)
committerhobbs <hobbs>2001-11-17 22:44:04 (GMT)
commit4bd4c9a955977c457ddf8795c30e14681c135966 (patch)
tree7c838c6b24a2cd0a0dec95394c742f7c6629e2a8 /tests
parent8d9513343233733ed7901dd08168ad51e8560837 (diff)
downloadtk-4bd4c9a955977c457ddf8795c30e14681c135966.zip
tk-4bd4c9a955977c457ddf8795c30e14681c135966.tar.gz
tk-4bd4c9a955977c457ddf8795c30e14681c135966.tar.bz2
* win/tkWinButton.c (TkpComputeButtonGeometry): corrected the
default size of Windows buttons to conform to the Windows style. This changes the default size of buttons on Windows. [Patch #463234] (nelson) **** POTENTIAL VISUAL INCOMPATABILITY ****
Diffstat (limited to 'tests')
-rw-r--r--tests/button.test6
-rw-r--r--tests/winButton.test23
2 files changed, 9 insertions, 20 deletions
diff --git a/tests/button.test b/tests/button.test
index 543f595..67f019b 100644
--- a/tests/button.test
+++ b/tests/button.test
@@ -7,7 +7,7 @@
# Copyright (c) 1998-1999 by Scriptics Corporation.
# All rights reserved.
#
-# RCS: @(#) $Id: button.test,v 1.9 2000/05/25 16:57:24 ericm Exp $
+# RCS: @(#) $Id: button.test,v 1.10 2001/11/17 22:44:04 hobbs Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
source [file join [pwd] [file dirname [info script]] defs.tcl]
@@ -749,7 +749,9 @@ test button-11.1 {ButtonTextVarProc procedure} {
} {Label Label New}
test button-11.2 {ButtonTextVarProc procedure} {
eval destroy [winfo children .]
- set x Label
+ # Windows buttons have a default min width, so we have to
+ # set this to be longer to force the wider button.
+ set x ExtraLongLabel
button .b1 -textvariable x
set old [winfo reqwidth .b1]
set x New
diff --git a/tests/winButton.test b/tests/winButton.test
index 48a60d5..afa7f36 100644
--- a/tests/winButton.test
+++ b/tests/winButton.test
@@ -8,7 +8,7 @@
# Copyright (c) 1998-1999 by Scriptics Corporation.
# All rights reserved.
#
-# RCS: @(#) $Id: winButton.test,v 1.4 1999/04/16 01:51:43 stanton Exp $
+# RCS: @(#) $Id: winButton.test,v 1.5 2001/11/17 22:44:04 hobbs Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
source [file join [pwd] [file dirname [info script]] defs.tcl]
@@ -57,7 +57,7 @@ test winbutton-1.1 {TkpComputeButtonGeometry procedure} {pcOnly} {
[winfo reqwidth .b2] [winfo reqheight .b2] \
[winfo reqwidth .b3] [winfo reqheight .b3] \
[winfo reqwidth .b4] [winfo reqheight .b4]
-} {68 48 71 51 96 50 96 50}
+} {68 48 70 50 88 50 88 50}
test winbutton-1.2 {TkpComputeButtonGeometry procedure} {pcOnly} {
eval destroy [winfo children .]
label .b1 -bitmap question -bd 3 -padx 0 -pady 2
@@ -70,7 +70,7 @@ test winbutton-1.2 {TkpComputeButtonGeometry procedure} {pcOnly} {
[winfo reqwidth .b2] [winfo reqheight .b2] \
[winfo reqwidth .b3] [winfo reqheight .b3] \
[winfo reqwidth .b4] [winfo reqheight .b4]
-} {23 33 26 36 51 35 51 35}
+} {23 33 25 35 43 35 43 35}
test winbutton-1.3 {TkpComputeButtonGeometry procedure} {pcOnly} {
eval destroy [winfo children .]
label .b1 -bitmap question -bd 3 -highlightthickness 4
@@ -84,7 +84,7 @@ test winbutton-1.3 {TkpComputeButtonGeometry procedure} {pcOnly} {
[winfo reqwidth .b2] [winfo reqheight .b2] \
[winfo reqwidth .b3] [winfo reqheight .b3] \
[winfo reqwidth .b4] [winfo reqheight .b4]
-} {31 41 24 34 26 36 26 36}
+} {31 41 23 33 25 35 25 35}
test winbutton-1.4 {TkpComputeButtonGeometry procedure} {pcOnly nonPortable} {
eval destroy [winfo children .]
label .b1 -text Xagqpim -bd 2 -padx 0 -pady 2 -font {{MS Sans Serif} 8}
@@ -145,22 +145,9 @@ test winbutton-1.9 {TkpComputeButtonGeometry procedure} {pcOnly} {
eval destroy [winfo children .]
button .b2 -bitmap question -default normal
list [winfo reqwidth .b2] [winfo reqheight .b2]
-} {24 34}
+} {23 33}
# cleanup
eval destroy [winfo children .]
::tcltest::cleanupTests
return
-
-
-
-
-
-
-
-
-
-
-
-
-