Skip to content

Commit

Permalink
Remove dot lexer from docs
Browse files Browse the repository at this point in the history
Closes #37
  • Loading branch information
kjellmf committed Mar 15, 2019
1 parent 0f35614 commit db73048
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
14 changes: 7 additions & 7 deletions docs/customization_guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ The dot language defines the ``style`` attribute that can be used to modify the

The following example shows how interesting visual results can be achieved with the PGF/TikZ output format. The styles are PGF/TikZ specific. See the user guide for details:

.. sourcecode:: dot
::

graph G {
node [shape=circle, fixedsize=True, width="0.2",
Expand Down Expand Up @@ -44,7 +44,7 @@ Changing arrow types

The style attribute can be used to change arrow types. A PGF/TikZ example:

.. sourcecode:: dot
::

digraph G {
graph [mindist=0.5];
Expand Down Expand Up @@ -77,7 +77,7 @@ You can also set the default arrow style by using the ``--graphstyle`` option or

A PSTricks example:

.. sourcecode:: dot
::

digraph G {
d2tdocpreamble="\usepackage{pstricks-add}";
Expand Down Expand Up @@ -124,7 +124,7 @@ When you specify a ``lblstyle`` attribute, the style will be given as a paramete

Example:

.. sourcecode:: dot
::

digraph G {
node [shape=circle];
Expand Down Expand Up @@ -175,7 +175,7 @@ With the ``--tikzedgelabel`` option you can bypass the XDOT edge label placement

Example:

.. sourcecode:: dot
::

graph G {
mindist = 0.5;
Expand Down Expand Up @@ -225,7 +225,7 @@ The ``topath`` edge attribute offers a way to override the edges drawn by Graphv

Example:

.. sourcecode:: dot
::

digraph G {
mindist = 0.5;
Expand Down Expand Up @@ -258,7 +258,7 @@ The generated edge drawing code is:

Here is a larger example that uses the ``automata`` library:

.. sourcecode:: dot
::

digraph G {
d2tdocpreamble = "\usetikzlibrary{automata}";
Expand Down
4 changes: 2 additions & 2 deletions docs/tipsandtricks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ So instead of typing::

each time, use ``d2toptions`` like this:

.. sourcecode:: dot
::

digraph G {
d2toptions ="-tikz -tmath --tikzedgelabels";
Expand All @@ -76,7 +76,7 @@ Use the tikz output format for maximum flexibility

The difference between the ``pgf`` and ``tikz`` output formats is best shown with an example. Consider the following graph:

.. sourcecode:: dot
::

graph G {
mindist = 0.5;
Expand Down
14 changes: 7 additions & 7 deletions docs/usage_guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ Label examples

Consider the following graph:

.. sourcecode:: dot
::

digraph G {
a_1-> a_2 -> a_3 -> a_1;
Expand All @@ -278,7 +278,7 @@ gives the result shown in the left hand side of the figure below. The default re

Example of using ``texlbl``:

.. sourcecode:: dot
::

digraph G {
a_1 [texlbl="$\frac{\gamma}{x^2}$"];
Expand All @@ -290,7 +290,7 @@ Example of using ``texlbl``:

Example of using the ``texmode`` attribute:

.. sourcecode:: dot
::

digraph G {
a_1 [texlbl="$\frac{\gamma}{2x^2+y^3}$"];
Expand Down Expand Up @@ -331,7 +331,7 @@ Dot2tex relies on the xdot format for drawing nodes and placing node labels. The

Here is an example graph where it is necessary to use the ``valignmode`` option:

.. sourcecode:: dot
::

digraph G {
node0 [label="{left|right}", shape=record];
Expand Down Expand Up @@ -367,7 +367,7 @@ PSTricks users have to use the ``--alingstr`` option::

The result is better, but to get even better alignment you have to change the node font size. Graphviz' default font size is 14pt, which is larger than the typical 10pt or 11pt used in LaTeX documents. By changing the node font size to 10pt we can trick Graphviz to give us a better alignment:

.. sourcecode:: dot
::

digraph G {
node [fontsize=10];
Expand Down Expand Up @@ -415,7 +415,7 @@ Examples

Consider the following graph:

.. sourcecode:: dot
::

digraph G {
node [shape=circle];
Expand Down Expand Up @@ -453,7 +453,7 @@ The resulting graph now has correctly sized nodes and edge labels:

Modifying node sizes using the ``widht/height`` and ``margin`` attributes can be a bit counterintuitive. A few examples will hopefully make it clearer:

.. sourcecode:: dot
::

digraph G {
node [shape=rectangle];
Expand Down

0 comments on commit db73048

Please sign in to comment.