Explorer: A Tree Navigator example

In this sample, it is demonstrated how to use non-default icons for the nodes, and the scaling of the nodes is adjusted to accomodate the size of the icons.

This is what the tree look like:

The configuration file is displayed below:
 

# Tree Navigator configuration file
# This file describes a traditional explorer type tree

#set the deafult open folder icon
openimage = "open.gif"

#set the default closed folder icon
closedimage = "closed.gif"

# show connecting lines between nodes
showlines = yes

# set xscale and yscale to ovoid icon overlapping.
xscale = 28
yscale = 25

# why not make the tree square
xsize = 200
ysize = 150

# white text on a blue background
text = 255,255,255
background = 0,0,140

highlight and raise with white 
highlight = 255,255,255 
raise = 255,255,255

# and now the nodes
node = {
  name = "root"

  node = {
    name = "a TeX document"
    # override the default icon
    leafimage = "tex.gif"
  }

  node = {
    name = "a plain text document"
    # override the default icon
    leafimage = "text.gif"
  }
}
 

That was the configuration file. The tree is placed below by using this tag:
<applet
  ARCHIVE  = "../navtree.jar"
  CODEBASE = "."
  CODE     = "aves.navtree.NavTree.class"
  NAME     = "TestApplet"
  WIDTH    = 200
  HEIGHT   = 150
  HSPACE   = 0
  VSPACE   = 0
  ALIGN    = middle
>
<param name="config" value="explorer.def">
</applet>