I read @trianta’s 2017 off-the-wall request to Export map view to DOT. Would that be doable, and desirable(? and thought: it must be doable! (I completely ignored the desirable part.)
So here we go, a template to export a map view into a dot
file that can be converted to PDF using Graphviz: graphiz export.tbx (201.1 KB)
The template has a README note explaining how to use it.
They key things were to use a rule to collect all the outbound links into a string:
$MyString="";
$MyList=links.outbound..$Name;
$MyList.each(x){$MyString = $MyString + '"' + $Name + '" -> ' + '"' + x + '"\n';};
And to use the right templates. First, the parent note:
/* Define global attributes here. */
digraph mygraph {
^children("/Templates/Dot/Dot item")
}
Then the child notes simply export the string value:
^value($MyString)^
Here’s what the Tinderbox map looked like:
And here’s the Graphviz diagram:
My intent was to use Tinderbox to make interrelationship diagrams and Graphbviz to “flatten” them so I can see the dependencies. It works quite well.