dominikbraun / graph

A library for creating generic graph data structures and modifying, analyzing, and visualizing them.
https://graph.dominikbraun.io
Apache License 2.0
1.8k stars 94 forks source link

Graph attributes #91

Closed RealHarshThakur closed 1 year ago

RealHarshThakur commented 1 year ago

Is it possible to have a generic Graph attributes that can be passed like Vertex/Edge to GraphViz?

I was looking at adding this but couldn't find anything : rankdir=LR;

dominikbraun commented 1 year ago

Hi, graph attributes for draw.DOT will likely come with the next release. General graph attributes are planned too, but require a bit more thought to implement.

dominikbraun commented 1 year ago

Support for global graph attributes for draw.DOT has been added in release v0.17.0:

_ = draw.DOT(g, file, draw.GraphAttribute("label", "my-graph"))

CC @RealHarshThakur @christophetd

christophetd commented 1 year ago

Thanks for the note! I had to temporarily switch to https://github.com/awalterschulze/gographviz for this, I guess I can switch back to graph now

RealHarshThakur commented 1 year ago

Amazing, thanks for the quick turnaround! :)

dominikbraun commented 1 year ago

Since this issue only concerns Graphviz, I'm going to close it for now. There's also #76 for general graph attributes.