diff options
author | treectrl <treectrl> | 2005-05-13 20:29:13 (GMT) |
---|---|---|
committer | treectrl <treectrl> | 2005-05-13 20:29:13 (GMT) |
commit | 8323f2a7eaac30f421e11a0372436c496c0443fc (patch) | |
tree | ce47ef8423dcb8bdb47bec0c88ed5fb4a2cdaac6 /demos/layout.tcl | |
parent | 841d70662d15579fa28abf201dd0163f03390558 (diff) | |
download | tktreectrl-8323f2a7eaac30f421e11a0372436c496c0443fc.zip tktreectrl-8323f2a7eaac30f421e11a0372436c496c0443fc.tar.gz tktreectrl-8323f2a7eaac30f421e11a0372436c496c0443fc.tar.bz2 |
Use column -tag instead of zero, to handle -columnprefix option if used.
Diffstat (limited to 'demos/layout.tcl')
-rw-r--r-- | demos/layout.tcl | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/demos/layout.tcl b/demos/layout.tcl index 7a3ca89..4f67624 100644 --- a/demos/layout.tcl +++ b/demos/layout.tcl @@ -16,7 +16,8 @@ proc DemoLayout {} { # Create columns # - $T column create -text Layout + $T column create -text Layout -tag C0 + $T configure -treecolumn C0 # # Create elements @@ -52,12 +53,12 @@ proc DemoLayout {} { # set I [$T item create -button yes] - $T item style set $I 0 $S + $T item style set $I C0 $S $T item lastchild root $I set parent $I set I [$T item create] - $T item style set $I 0 $S + $T item style set $I C0 $S $T item lastchild $parent $I ### @@ -69,11 +70,11 @@ proc DemoLayout {} { $T style layout $S e4 -detach yes -iexpand es set I [$T item create -button yes] - $T item style set $I 0 $S + $T item style set $I C0 $S $T item lastchild root $I set I2 [$T item create] - $T item style set $I2 0 $S + $T item style set $I2 C0 $S $T item lastchild $I $I2 ### @@ -85,11 +86,11 @@ proc DemoLayout {} { $T style layout $S e5 -ipady {0 20} set I [$T item create -button yes] - $T item style set $I 0 $S + $T item style set $I C0 $S $T item lastchild root $I set I2 [$T item create] - $T item style set $I2 0 $S + $T item style set $I2 C0 $S $T item lastchild $I $I2 ### @@ -106,14 +107,14 @@ proc DemoLayout {} { $T style layout $S et -squeeze x set I [$T item create -button yes] - $T item style set $I 0 $S - $T item text $I 0 $text + $T item style set $I C0 $S + $T item text $I C0 $text $T item lastchild root $I set parent $I set I [$T item create] - $T item style set $I 0 $S - $T item text $I 0 $text + $T item style set $I C0 $S + $T item text $I C0 $text $T item lastchild $parent $I ### @@ -132,7 +133,7 @@ proc DemoLayout {} { incr styleNum set I [$T item create] - $T item style set $I 0 $S + $T item style set $I C0 $S $T item lastchild root $I } } |