Number: 200
Title: The options to avoid node-edge overlaps in neato fail for record shapes
Submitter: Kevin Ruscoe
Date: Tue Sep 17 15:46:37 2002
Subsys: Neato
Version: 1.8.9
System: Sparc-Solaris-8
Severity: major
Problem:
The FAQ included in the distribution of GraphViz v1.8.9 states:

"Q. How can I avoid node-edge overlaps in neato?

neato -Goverlap=false/scale -Gsplines=true -Gsep=.1

The sep argument is the node-edge separation as a ratio of a node's bounding box. (Don't ask why this isn't just a constant!) Note that this option really slows down neato, so should be used sparingly and only with modest-sized graphs."

I know this bug report sounds like a pretty obscure problem, but I would really like to use this feature. We have a number of huge graphs of database schemata. Currently, I produce directed graphs, but this does not look good when a given table has dozens of dependencies. In many cases, I believe that an undirected graph would be a better solution.

Unfortunately, although I can stop the nodes themselves from overlapping each other, the options to avoid node-edge overlaps have no effect when using nodes with a shape of record. No error messages are produced, but the "good" version in the example provided runs more slowly than the "bad" version, indicating that it is using the functionality.


$ neato -Tpng -o good.png -Goverlap=false -Gsplines=true -Gsep=.1 good.canon
$ neato -Tpng -o bad.png -Goverlap=false -Gsplines=true -Gsep=.1 bad.canon

Input:
good.png
--------
graph test {
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it;
foo;
bar;
bletch;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- foo;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- bar;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- bletch;
foo -- bar;
foo -- bletch;
bar -- bletch;
}

bad.png
-------
graph test {
node [shape=record];
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it;
foo;
bar;
bletch;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- foo;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- bar;
the_node_with_a_very_long_name_so_that_edges_will_definitely_cross_it -- bletch;
foo -- bar;
foo -- bletch;
bar -- bletch;
}
Output file: b200.png
Owner: erg
Status: Fixed (21 March 2003)