Re: Dia XML format, Graphviz, Instaviz etc.



At 27.03.2009 11:55, Lars Ræder Clausen wrote:
On Tue, 2009-03-24 at 07:15 +0900, Glen Low wrote:
[...]
Does Dia not have bezier splines?

It does, but they use a different model than graphviz does, and my
experience has been that the conversion is suboptimal.

Huh? From my experience they are pretty much the same. Yesterday I've patched dot's Dia output to better understand what was wrong with my PyDia script dot2dia.py. It now can parse the dot files generated by another tool of mine. The only major grief was the special order of bezierpoints in dot's edge definition:
  [pos="e,73447,3848 40408,888 40489,896 ..."]

At least it took me some time to understand, that the first point in the list is the end point. But after handling this it simply worked. See:
http://svn.gnome.org/viewvc/dia/trunk/plug-ins/python/dot2dia.py?revision=4347&view=markup

This issue is not relevant to dot's Dia bezier output though, so $(GRAPHVIS)/lib/common/diagen.c is coprrect in that aspect. It can just serialize the given points array to the .dia file. The first point is moveto, all other points are curveto; just Y needs to be mirrored.

        Hans

-------- Hans "at" Breuer "dot" Org -----------
Tell me what you need, and I'll tell you how to
get along without it.                -- Dilbert



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]