On Mon, Feb 16, 2009 at 6:21 PM, Georg Brandl <[email protected]> wrote:

>
> Michael Droettboom schrieb:
> > I have submitted inheritance_diagram.py to Sphinx already.  There didn't
> > seem to be much interest, and there were some details (particularly how
> > it deals with files), that weren't "the Sphinx way", and there few
> > documents and/or examples etc. at the time about how to do it right.
> > Someone else ended up re-engineering it to use pygraphviz which felt
> > pretty heavy weight to me.  So the thing kind of stalled.  But it's
> > probably worth another push.
>
> The mails are still in my "look at it again" folder.  I kind of agree
> that using pygraphviz is counterproductive, since many systems have
> graphviz but no so many, I suspect, pygraphviz.
>
> Is the current version of the inheritance_diagram.py the one in matplotlib?


That's the one that matplotlib is currently using for its own docs.  I don't
know if any new features exist in forks elsewhere -- which is why it's great
that Gael has taken it on to sort all this stuff out.

http://matplotlib.svn.sourceforge.net/viewvc/matplotlib/trunk/matplotlib/doc/sphinxext/inheritance_diagram.py?revision=6863&view=markup

It has been updated since the last time I mentioned it on the Sphinx list to
put the image files into the build directory -- it basically follows the
pattern used in the Sphinx built-in math extensions (this was sort of the
missing info I couldn't figure out on my own earlier).

One aspect that is not ideal is how it deals with cross-references.  The
HTML version produces a clickable image map that links to the documentation
of each class.  I manage this by stuffing xfile_ref nodes in the tree at
tree-building time, let Sphinx resolve those cross-references to real URLs,
and then pull them out when the graph node is later visited.  If there's a
way to convert a class name to a URL in a more direct way that I just wasn't
able to find, that would probably be less cumbersome.

Mike

-- 
Michael Droettboom
http://www.droettboom.com/

Sent from my MacBook Wheel

This message is confidential, intended only for the named recipient(s) and
may contain information that is privileged or exempt from disclosure under
applicable law. If you are not the intended recipient(s), you are notified
that any dissemination, distribution, or copying of this message is strictly
prohibited.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to