Skip to content

Fix link target path for SVG inheritance diagrams#2484

Closed
bsipocz wants to merge 1 commit intosphinx-doc:masterfrom
bsipocz:ext_inheritance_diagram_fix_linkpath
Closed

Fix link target path for SVG inheritance diagrams#2484
bsipocz wants to merge 1 commit intosphinx-doc:masterfrom
bsipocz:ext_inheritance_diagram_fix_linkpath

Conversation

@bsipocz
Copy link
Contributor

@bsipocz bsipocz commented Apr 23, 2016

The link target path for the SVG version of the inheritance diagram was incorrect (see examples below). This PR fixes it.

Examples:
http://docs.astropy.org/en/stable/coordinates/#class-inheritance-diagram
http://photutils.readthedocs.org/en/latest/photutils/aperture.html#class-inheritance-diagram

This fixes astropy/photutils#345.

Does it need a changelog entry?

@tk0miya
Copy link
Member

tk0miya commented Apr 24, 2016

sphinx.ext.inheritance_diagram embeds the diagram using <object> tag now. But it seems your document embeds the diagram directly into HTML. It might come from your original directive; automodapi.

This fix breaks behavior of sphinx.ext.inheritance_diagram. The hyperlinks in external SVG file should be relative URL from the file or absolute URL.

@tk0miya
Copy link
Member

tk0miya commented May 29, 2016

Now I close this. because this is not a bug of Sphinx.
Thanks,

@tk0miya tk0miya closed this May 29, 2016
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 22, 2021
@AA-Turner AA-Turner added extensions:graphviz The `sphinx.ext.graphviz` or `sphinx.ext.inheritance_diagram` extensions and removed extensions labels Jan 29, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

extensions:graphviz The `sphinx.ext.graphviz` or `sphinx.ext.inheritance_diagram` extensions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Broken links in class inheritance diagram docs.

3 participants