Is there a good diagramming library for Python?
I should say I'm looking for something interactive, equivalent to what Nevron offers in it's .NET Diagram product, where a user can create nodes, interact with them by dragging them around, etc. I know there's GraphViz, but as far as I know it's static, and just renders a graph/diagram, there is no interaction with it.
I have a 开发者_开发知识库bad feeling there is nothing as rich as this in the cross platform world for Python or any other script language, but maybe I've missed it.
Ubigraph is probably not what you want, but is still really excellent.
I have been searching for a solution to this myself for quite some time, and have just come across an Apache 2.0 licensed project based on Cairo and GTK, called Gaphas.
It has diagram widgets allowing user placement and interaction, and appears to be quite active.
There's also a python-code generated diagram library (appropriately, and perhaps confusingly) called Diagrams, which you may be able to borrow from, though doesn't appear interactive.
Writing graphviz dot files is a good way to go. Google for graphviz and see http://code.google.com/p/pydot/ for a python wrapper.
精彩评论