summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorpspjuth <peter.spjuth@gmail.com>2002-11-07 19:10:29 (GMT)
committerpspjuth <peter.spjuth@gmail.com>2002-11-07 19:10:29 (GMT)
commitcece78a79dbca5151f873198cc5a089a0fd5cbdc (patch)
tree44db78d5717f104b3dfe4d0554d0fa4d9bfd757e /tests
parent13643396a4973234dcdcbb92f77bb3eceaf2e255 (diff)
downloadtk-cece78a79dbca5151f873198cc5a089a0fd5cbdc.zip
tk-cece78a79dbca5151f873198cc5a089a0fd5cbdc.tar.gz
tk-cece78a79dbca5151f873198cc5a089a0fd5cbdc.tar.bz2
place info did not return all settings,
and didn't make sure the result was a proper list. Put '-in' first in result to be more consistent with how grid/pack info behaves. [Bug #635025][Bug #532022]
Diffstat (limited to 'tests')
-rw-r--r--tests/place.test16
1 files changed, 13 insertions, 3 deletions
diff --git a/tests/place.test b/tests/place.test
index 02d87ac..4bf47fb 100644
--- a/tests/place.test
+++ b/tests/place.test
@@ -5,7 +5,7 @@
# Copyright (c) 1998-1999 by Scriptics Corporation.
# All rights reserved.
#
-# RCS: @(#) $Id: place.test,v 1.7 2002/07/13 20:28:35 dgp Exp $
+# RCS: @(#) $Id: place.test,v 1.8 2002/11/07 19:10:30 pspjuth Exp $
package require tcltest 2.1
namespace import -force tcltest::configure
@@ -27,13 +27,23 @@ update
test place-1.1 {Tk_PlaceCmd procedure, "info" option} {
place .t.f2 -x 0
place info .t.f2
-} {-x 0 -relx 0 -y 0 -rely 0 -width {} -relwidth {} -height {} -relheight {} -anchor nw}
+} {-in .t -x 0 -relx 0 -y 0 -rely 0 -width {} -relwidth {} -height {} -relheight {} -anchor nw -bordermode inside}
test place-1.2 {Tk_PlaceCmd procedure, "info" option} {
place .t.f2 -x 1 -y 2 -width 3 -height 4 -relx 0.1 -rely 0.2 \
-relwidth 0.3 -relheight 0.4 -anchor se -in .t.f \
-bordermode outside
place info .t.f2
-} {-x 1 -relx 0.1 -y 2 -rely 0.2 -width 3 -relwidth 0.3 -height 4 -relheight 0.4 -anchor se -bordermode outside -in .t.f}
+} {-in .t.f -x 1 -relx 0.1 -y 2 -rely 0.2 -width 3 -relwidth 0.3 -height 4 -relheight 0.4 -anchor se -bordermode outside}
+test place-1.3 {Tk_PlaceCmd procedure, "info" option} {
+ # Make sure the result is built as a proper list by using a space in parent
+ frame ".t.a b"
+ place .t.f2 -x 1 -y 2 -width {} -height 4 -relx 0.2 -rely 0.2 \
+ -relwidth 0.3 -relheight {} -anchor w -in ".t.a b" \
+ -bordermode ignore
+ set res [place info .t.f2]
+ destroy ".t.a b"
+ set res
+} {-in {.t.a b} -x 1 -relx 0.2 -y 2 -rely 0.2 -width {} -relwidth 0.3 -height 4 -relheight {} -anchor w -bordermode ignore}
test place-2.1 {ConfigureSlave procedure, -height option} {
list [catch {place .t.f2 -height abcd} msg] $msg