Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Is there a way to get values for predefined dash patterns such as dotted? I would like to use those in another program to create the same visual experience. Or do I have to define my own patterns in order to have the same values?

share|improve this question
add comment

1 Answer

up vote 18 down vote accepted

You can find the definitions of these and many others in the tikz.code.tex file in your distribution (e.g. MikTeX has it under C:\Program Files (x86)\MiKTeX 2.9\tex\generic\pgf\frontendlayer\tikz\ )

\tikzstyle{solid}=                   [dash pattern=]
\tikzstyle{dotted}=                  [dash pattern=on \pgflinewidth off 2pt]
\tikzstyle{densely dotted}=          [dash pattern=on \pgflinewidth off 1pt]
\tikzstyle{loosely dotted}=          [dash pattern=on \pgflinewidth off 4pt]
\tikzstyle{dashed}=                  [dash pattern=on 3pt off 3pt]
\tikzstyle{densely dashed}=          [dash pattern=on 3pt off 2pt]
\tikzstyle{loosely dashed}=          [dash pattern=on 3pt off 6pt]
\tikzstyle{dashdotted}=              [dash pattern=on 3pt off 2pt on \the\pgflinewidth off 2pt]
\tikzstyle{densely dashdotted}=      [dash pattern=on 3pt off 1pt on \the\pgflinewidth off 1pt]
\tikzstyle{loosely dashdotted}=      [dash pattern=on 3pt off 4pt on \the\pgflinewidth off 4pt]
share|improve this answer
2  
Damn, you beat me to it by about 15 seconds! This is better than my one too, so +1! –  qubyte Feb 21 '12 at 12:58
    
Thanks for the very quick answer! –  Eike Feb 21 '12 at 13:09
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.