summaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
authortreectrl <treectrl>2006-11-05 06:48:34 (GMT)
committertreectrl <treectrl>2006-11-05 06:48:34 (GMT)
commitdea40b9b862fad5ebe4bc636ecf4de2ae52b5700 (patch)
tree01ceffd71ad8f31c3ab68bc29d51cb5e56b2ede2 /demos
parentdbb872605b6aea9aa294582fcc5131265f9920c8 (diff)
downloadtktreectrl-dea40b9b862fad5ebe4bc636ecf4de2ae52b5700.zip
tktreectrl-dea40b9b862fad5ebe4bc636ecf4de2ae52b5700.tar.gz
tktreectrl-dea40b9b862fad5ebe4bc636ecf4de2ae52b5700.tar.bz2
Replaced use of deprecated treectrl option -defaultstyle with new column option -itemstyle.
Set the size of window element box in the canvas to the [winfo width] instead of [winfo reqwidth] to support the -clip option (since the borderless frame usually has zero requested size).
Diffstat (limited to 'demos')
-rw-r--r--demos/style-editor.tcl12
1 files changed, 6 insertions, 6 deletions
diff --git a/demos/style-editor.tcl b/demos/style-editor.tcl
index 9336df1..54ddea0 100644
--- a/demos/style-editor.tcl
+++ b/demos/style-editor.tcl
@@ -1,4 +1,4 @@
-# RCS: @(#) $Id: style-editor.tcl,v 1.9 2006/10/28 01:24:13 treectrl Exp $
+# RCS: @(#) $Id: style-editor.tcl,v 1.10 2006/11/05 06:48:34 treectrl Exp $
namespace eval StyleEditor {
variable Info
@@ -142,7 +142,7 @@ proc StyleEditor::SetListOfStyles {} {
$T style elements s1 {e2 e1}
$T style layout s1 e2 -union [list e1] -ipadx 2 -ipady 2 -iexpand e
- $T configure -defaultstyle s1
+ $T column configure C0 -itemstyle s1
}
# Clear the list
@@ -200,7 +200,7 @@ proc StyleEditor::SetListOfElements {style} {
$T style elements s1 {e2 e1}
$T style layout s1 e2 -union [list e1] -ipadx 2 -ipady 2 -iexpand e
- $T configure -defaultstyle s1
+ $T column configure C0 -itemstyle s1
}
# Clear the list
@@ -296,7 +296,7 @@ proc StyleEditor::SetPropertyList {} {
$T configure -font [[Info editor,pad].v1 cget -font] \
-minitemheight $height
- $T configure -defaultstyle s1
+ $T column configure 0 -itemstyle s1
}
$T item delete all
@@ -748,8 +748,8 @@ proc StyleEditor::StyleToCanvas {{scroll 0}} {
}
if {$sameAsMaster} {
} elseif {$name eq "-window"} {
- $T style layout $style $E -width [winfo reqwidth $current] \
- -height [winfo reqheight $current]
+ $T style layout $style $E -width [winfo width $current] \
+ -height [winfo height $current]
} else {
$T element configure $E $name $current
}