annotate toolboxes/graph_visualisation/share/graphviz/doc/latex_suggestions.txt @ 0:cc4b1211e677 tip

initial commit to HG from Changeset: 646 (e263d8a21543) added further path and more save "camirversion.m"
author Daniel Wolff
date Fri, 19 Aug 2016 13:07:06 +0200
parents
children
rev   line source
Daniel@0 1 --- vladimir@worklogic.com: this below isn't implemented yet! ---
Daniel@0 2 --- Talk to me if you're interested in it and want to help ---
Daniel@0 3 Latex/Psfrag Attributes+
Daniel@0 4 Only work in -Tps and if latex2e and psfrag.sty ver.3 are installed.
Daniel@0 5 The resulting ps file will print latex commands unless you include it in a
Daniel@0 6 tex file that does \usepackage[scanall]{psfrag}, or run it through the
Daniel@0 7 supplied script "psfrag" (which wraps it in such a tex file).
Daniel@0 8
Daniel@0 9 psfrag: string [GNE]. This text is passed through latex.
Daniel@0 10 Example: node: a1 [psfrag="$\alpha_1$"]
Daniel@0 11 edge: x->y [label="x -> y" psfrag="$x \rightarrow y$"]
Daniel@0 12 The name/label is used only as a guide for positioning, but you better
Daniel@0 13 specify them. E.g. if the edge had no label attribute, dot would have to
Daniel@0 14 assume that the label is 17 characters wide.
Daniel@0 15 The line breaks \l,\n,\r are *not* processed in the psfrag attribute.
Daniel@0 16 If you want line breaks, arrange it with latex commands, and *also* specify
Daniel@0 17 a label that emulates the breaks.
Daniel@0 18 tailpsfrag/headpsfrag: string [E]. Same for tail/head of the edge.
Daniel@0 19 fontname: [GNE] Use any of the commands described in latex2e's fntguide.
Daniel@0 20 If the command sequence contains %s, the text is inserted there. Else the
Daniel@0 21 text is preceded by the command, all surrounded by braces. For example, if
Daniel@0 22 the text is "..." then \texttt{%s} becomes \texttt{...}, and \ttfamily
Daniel@0 23 becomes {\ttfamily ...}.
Daniel@0 24 If fontname matches "tt" then dot will use fixed font width for its
Daniel@0 25 positioning (is 0.65 right??). If fontname matches "bf" then dot will
Daniel@0 26 multiply the width for positioning purposes by ?? (for all families??).
Daniel@0 27 You cannot change the font by simply giving a different font name.
Daniel@0 28 E.g. to switch to Courier, you either have to use \texttt{%s} with a style
Daniel@0 29 that uses Postscript fonts, or else use \fontfamily{pcr}\selectfont ("pcr"
Daniel@0 30 stands for postscript courier). As a precaution, dot won't output a fontname
Daniel@0 31 that does not contain \.
Daniel@0 32 Often used commands are \rmfamily (roman), \sffamily (sans serif),
Daniel@0 33 \ttfamily (typewriter), \mdseries (medium, i.e. normal), \bfseries (bold),
Daniel@0 34 \upshape (upright, i.e. normal), \itshape (italic), \slshape (slanted),
Daniel@0 35 \scshape (small caps); or their equivalents \textrm{%s}, ...; \boldmath;
Daniel@0 36 \mathcal{%s}.
Daniel@0 37 fontsize: "n\cmd". [GNE] Dot assumes for positioning purposes that the font is
Daniel@0 38 n points high, and emits the font changing command \cmd to latex. Both n and
Daniel@0 39 \cmd are optional.
Daniel@0 40 If \cmd is missing then you are informing dot that the latex fontsize is n.
Daniel@0 41 *Please* do this at the top level. The default 14 is probably wrong for you.
Daniel@0 42 The correct setting for a 10pt article style is "digraph G {fontsize=10 ...}"
Daniel@0 43 If you use "n!", dot will force this size to latex by emitting commands
Daniel@0 44 \fontsize\selectfont. This is not smart unless you use scalable fonts, eg
Daniel@0 45 postscript fonts.
Daniel@0 46 If n is missing and \cmd is one of the standard commands \tiny,
Daniel@0 47 \scriptsize, \footnotesize, \normalsize, \large, \Large, \LARGE, \huge or
Daniel@0 48 \HUGE, dot will compute the new size automatically. Otherwise you have to
Daniel@0 49 specify both.
Daniel@0 50 If the command contains %s, the text will be inserted there, else the
Daniel@0 51 text is preceded by the command, all surrounded by braces.