ClassyTcl

  Tree

Home    Documentation    Screenshots    Binary distributions    Source distribution   

subclass of Class
Tree is not a widget type. It is a class whose objects can be associated with a canvas widget. When a Tree instance is associated with a canvas, it will draw a tree on this canvas.

Tree options

A tree object supports the following options in its configure method
-canvas
name of canvas to draw the chart
-tag
unique tag for all canvas items of the chart
-padx
size of indentation
-pady
size left open between different lines
-font
default font for the text lines
-padtext
size between text parts
-startx
x location of root
-starty
y location of root
-rootimage
optional image displayed on root
-roottext
optional text displayed on root

Tree specific methods

pathname destroy
pathname configure ?option? ?value? ?option value ...?
changes the way the tree is displayed. Supported options are given above.
pathname addnode parent node args
add a node to node $parent. The following arguments can be given:
pathname closenode node
pathname opennode node
pathname clearnode node
pathname deletenode node
pathname exists node
pathname type node
pathname node ...
pathname what ...
pathname parentnode node
pathname children node
pathname selection ?option? ...
pathname nodes parent
returns the child nodes from $parent
Peter De Rijk
hosted at SourceForge.net Logo