Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to force position of edges in graphviz?

I'm having problems with edges overlapping each other. In my previous question of how to force the nodes to be in the same column, found out how to force the nodes in to one column, but this causes some other problems to appear.

digraph exmp {
  A -> B -> C -> D -> E
  C -> F [constraint=false]
  A -> C [style="dotted", constraint=false]
  A -> D [style="dotted",  constraint=false]
  B -> D [constraint=false]
  D -> A [style="dashed", constraint=false]
  C -> A [style="dashed", constraint=false]
  E -> F [style="invis"] 
  F -> G
  E -> C [constraint="false"]
}

Renders to:

alt text http://img98.imageshack.us/img98/8324/wrong2.gif

My problem is that the edges from E -> C and C -> F are starting/ending at the same point in the node C and the dashed and dotted edges are all on the right side of the nodes.

How could I tell specific edges to go to the right side of the node?

like image 963
Davy Landman Avatar asked Sep 25 '09 14:09

Davy Landman


1 Answers

After a message in the graphviz mail list I've found that's at least possible to remove the E -> C and C -> F overlapping problem.

The simplest solution is to use a compass point port:

C:e -> F [constraint=false]

-- Emden

like image 124
Davy Landman Avatar answered Sep 18 '22 09:09

Davy Landman