aboutsummaryrefslogtreecommitdiff
path: root/demos/labelformat.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'demos/labelformat.tcl')
-rw-r--r--demos/labelformat.tcl7
1 files changed, 4 insertions, 3 deletions
diff --git a/demos/labelformat.tcl b/demos/labelformat.tcl
index 9095992..8d9f2a3 100644
--- a/demos/labelformat.tcl
+++ b/demos/labelformat.tcl
@@ -26,7 +26,10 @@ pack $w.buttons.dismiss $w.buttons.code -side left -expand 1
text $w.text -relief sunken -borderwidth 2 -height 4
pack $w.text -expand yes -fill both
-$w.text insert end "This toy-appli demonstrates the use of labelformat for tabular items.\nThe fieldPos (please, refer to the labelformat type description\nin the Zinc reference manual) of each field as described in\nthe labelformat is displayed inside the field."
+$w.text insert end {This scipt demonstrates the use of labelformat for tabular items.
+The fieldPos (please, refer to the labelformat type description
+in the Zinc reference manual) of each field as described in
+the labelformat is displayed inside the field.}
###########################################
@@ -40,10 +43,8 @@ pack $w.zinc
proc setLabelContent {item labelformat} {
global w
set i 0
- puts "Label: $item: $labelformat"
foreach fieldSpec $labelformat {
set posSpec $i
- puts ":$i:$fieldSpec:"
regexp {^.\d+.\d+(.*)} $fieldSpec "" posSpec
$w.zinc itemconfigure $item $i -text "$i: $posSpec" -border "contour"
incr i