<TITLE>Arcadia: CU Arcadia: Tk Canvas Graph Layout Version 1.1</TITLE>

<h1>
<a href="http://www.cs.colorado.edu/homes/arcadia/public_html/Home.html">
CU Arcadia</a> Project:
Tk Canvas Graph Layout
</h1>

<h2>Location:</h2>
<ul>
<li> Latest Version: tklayout 1.1.
<li> Matching Tk Version: Tk 3.6.
<li> Release date: 21 June 1994

<li> README file via WWW:
<lb>http://www.cs.colorado.edu/homes/arcadia/public_html/tklayout1.1.html
<li>
<a href="ftp://ftp.cs.colorado.edu/pub/cs/distribs/arcadia/tklayout1.1.tar.Z">
Source</a>:
<ul>
<li> Via anonymous ftp: <pre>
machine: ftp.cs.colorado.edu (128.138.243.151)
directory: /pub/cs/distribs/arcadia
file: tklayout.tar.Z (symbolic link to latest version)
</pre>
</ul>
</ul>

<h2>Acknowledgement</h2>
This software is a mild re-write and a re-packaging of a portion of
the tkMegaWidget and tkIcon system of of Sven Delmas
(garfield@cs.tu-berlin.de) of the Tech. Univ. Berlin.
Sven's TkIcon system provided a very nice and useful
mechanism for defining graphs (node icons + edge canvas items)
and doing layout over them.
<p>
This re-package  was constructed
because the original tkIcon+tkMegaWidget system,
made me uncomfortable with the amount of modification
to the Tk sources that it required.  It was a bit too heavyweight.
This re-packaging sacrifices some features for simpler insertion
into Tk (see installation below).

<h2>Description<\h2>
The Tk canvas window type has been augmented
to allow graph layout of the selected canvas items.
It operates by associating extra graph information
with the canvas.  Items are created
using the normal canvas operations.
Any existing item may, by a separate command to the canvas,
be added to or removed from the list of items layed-out by the graph.
Four styles of layout are currently supported: ISI, Tree, Random, and Matrix.
Some simple experiments will demonstrate the differences.
A new type of item, Edge (taken from tkIcon)
is provided as the means of laying edges between nodes.
Non-edge canvas items are treated as nodes, but
not all canvas item types can be handled by the graph layout code.
A more complete description is provided by the graph.n file.

<h2>Installation:</h2>
The following source files are in the tar file of the distribution:
tkCanvas.c, tkCanvas.h, tkCanvEdge.c, layout.c, layout.h,
There are also some additional files such as
graph.n, Makefile.in, graphdemo.tcl, HISTORY, and README.html (this file).
<p>
In order to install, perform the following steps.
<ol>
<li> Un-tar the tklayout.tar file, this will produce a directory
named tklayout.
<li> Copy the files tkCanvas.c, tkCanvas.h, tkCanvEdge.c,
layout.c, and layout.h into your tk3.6 directory.
WARNING, this will overwrite the existing
tkCanvas.c and tkCanvas.h, so you may want to save them.
Note that I have tried to wrap all changes within an ifdef of CANVASLAYOUT.
<li> Modify your Makefile to build
tkCanvas.o and layout.o.  You can look at the tklayout/Makefile.in
to see how this might be done (or use that Makefile.in directly).
<li> Re-build and re-install Tk3.6.
<li> Start up the wish program and source tklayout/graphdemo.tcl.
Execute the demo command to see if things appear to be
working.
<\ol>

<h2>Contact and Bug Reports:</h2>
This is a rather quick and dirty re-packaging, and has not
been thoroughly tested, so I am sure that many bugs exist.
I would appreciate hearing about them, and better yet,
receiving patches.

<address>
<a href="http://www.cs.colorado.edu/homes/dennis/public_html/Home.html">
Dennis Heimbigner
</a>
(dennis@cs.colorado.edu)
</address>
