Graph rendering on dlang.org

H. S. Teoh via Digitalmars-d digitalmars-d at puremagic.com
Fri Jun 30 14:55:12 PDT 2017


On Fri, Jun 30, 2017 at 05:55:34PM -0400, Andrei Alexandrescu via Digitalmars-d wrote:
> On 06/30/2017 05:52 PM, Brian Schott wrote:
> > On Friday, 30 June 2017 at 21:40:05 UTC, Andrei Alexandrescu wrote:
> > > What would be a nice tool to render this DAG online? Who'd want to
> > > work on inserting this? Ideally it would be some vector rendering.
> > 
> > Graphviz's "dot" tool can output svg.
> > 
> > 
> > digraph "conversions" {
> >      "mutable" -> "const";
> >      "inout const" -> "const";
> >      "inout" -> "inout const";
> >      "immutable" -> "inout const";
> >      "immutable" -> "inout shared const";
> >      "inout shared" -> "inout shared const";
> >      "shared" -> "shared const";
> >      "inout shared const" -> "shared const";
> > }
> > 
> > dot -Tsvg conversions.dot > conversions.svg
> 
> Whoa, pretty nice: http://erdani.com/conversions.svg. How do I place the
> whole thing upside down? Thanks! -- Andrei

Like this:

	digraph {
		edge[dir="back"];
		const;
		const -> mutable;
		const -> "inout const";
		const -> inout;
		"inout const" -> immutable;
		"inout shared const" -> immutable;
		"inout shared const" -> "inout shared";
		"shared const" -> "inout shared const";
		"shared const" -> shared;
	}


T

-- 
Freedom: (n.) Man's self-given right to be enslaved by his own depravity.


More information about the Digitalmars-d mailing list