Dot2Texi -- combining Tikz and GraphViz
Tikz is one wonderful library for specifying graphics in latex, and I think one can do almost everything with it. However, the learning curve is too steep. I couldn’t see myself doing a lot of graphics related stuff, so I just learn the minimal set of Tikz to get me started.
Most of time, I find that I don’t need the power to specify all the details in one diagram; something like Graphviz works OK for me. Then, I find this
[blog], which illustrates how to combine tikz and graphviz using dot2texi. dot2tex
is one external program one needs to install, and it does the
translation from .dot
to .tex
, hence the name. After installing the dependency, the given example in the blog still doesn’t work. I need to change
the node style. (No idea why) The complete example could be found in this [gist].
§shell escape
Since external programs are used in building pdf, shell escape
has to be enabled, which is off by default for security reason, if fully automatic process is desired. I use xelatex
, so the
augmented command line should become xelatex --shell-escape
.
§output directory
The -output-directory
option is broken if dot2texi is used, for the generated .tex
from .dot
is put in the output directory, but dot2tex is
called in the current directory, as reported in this [issue].