Skip to content

Support for different Graphviz layouts #5124

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
digulla opened this issue Jun 25, 2018 · 4 comments
Closed

Support for different Graphviz layouts #5124

digulla opened this issue Jun 25, 2018 · 4 comments
Labels
extensions:graphviz The `sphinx.ext.graphviz` or `sphinx.ext.inheritance_diagram` extensions type:proposal a feature suggestion
Milestone

Comments

@digulla
Copy link

digulla commented Jun 25, 2018

Subject: Please add support to specify the layout per graph like so:

.. graphviz:: twopi2.gv
  :graphviz_layout: twopi

or even better:

.. graphviz:: twopi2.gv
  :layout: twopi

The argument should be passed to dot via the -K parameter.

The goal is to be able to render this demo from the gallery correctly: https://graphviz.gitlab.io/_pages/Gallery/twopi/twopi2.html

Environment info

  • OS: All
  • Python version: All
  • Sphinx version: 1.4.6
  • Extension: sphinx.ext.graphviz
@tk0miya
Copy link
Member

tk0miya commented Jun 25, 2018

graphviz directive already supports to switch rendering command with :graphviz_dot: option:

.. graphviz::
   :graphviz_dot: twopi

   digraph { A -> B, C, D, E }

Certainly, :layout: is a bit more elegant to choose layout engine to me.

@tk0miya tk0miya added extensions type:proposal a feature suggestion labels Jun 25, 2018
@digulla
Copy link
Author

digulla commented Jun 29, 2018

Thanks, this works.

@digulla digulla closed this as completed Jun 29, 2018
@digulla
Copy link
Author

digulla commented Jun 29, 2018

Oops...

@digulla digulla reopened this Jun 29, 2018
@tk0miya tk0miya added this to the 2.2.0 milestone Jun 1, 2019
tk0miya added a commit to tk0miya/sphinx that referenced this issue Jun 2, 2019
tk0miya added a commit to tk0miya/sphinx that referenced this issue Jun 2, 2019
tk0miya added a commit that referenced this issue Jun 15, 2019

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Close #5124: graphviz: :graphviz_dot: option is renamed to :layout:
@tk0miya
Copy link
Member

tk0miya commented Jun 15, 2019

Fixed by #6430.
Thank you for your proposal.

@tk0miya tk0miya closed this as completed Jun 15, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 3, 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 type:proposal a feature suggestion
Projects
None yet
Development

No branches or pull requests

3 participants