Re: pydia: get connection direction



At 03.08.2011 10:39, Martin Bretschneider wrote:
Hi,

I use Dia with the Python plugin (pyida) downloaded following the instructions
from http://dia-installer.de/howto/python_win32/ .

I want to write an export filter that print the objects (like boxes) and the
connection of these boxes into a XML file (see the attached Dia XML file).
Export-object.py from the Dia's installation folder gives a good start, it also
prints the connections but not the connection direction. In other words I do not
now where the arrow of the connections points to

First thing would be to understand Dia's model of Handle and ConnectionPoint, explained in more detail in e.g. http://mail.gnome.org/archives/dia-list/2008-July/msg00086.html even with PyDia sample ;)

The diagram accompaning pydiadoc.py might also help, please see:
http://live.gnome.org/Dia/Python

Finally there is at least on example in the Dia source tree, see:
http://git.gnome.org/browse/dia/tree/plug-ins/python/autolayoutforce.py

HTH,
        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]