TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I draw two loops above a node? Here is my code:

\path (r) edge[loop above] node[left=1pt] {3} (r);
\path (r) edge[out=140, in=50, looseness=0.8, loop] node[above=3pt] {4} (r);

How can I make the 2nd loop bigger, so that I get more space in between the loops?

Thanks in advance

share|improve this question
up vote 4 down vote accepted

You want the distance key, which sets both min distance and max distance (ignoring any computation). If you want less control, you can just specify one of those two. For more information, check out section 44.3, "Curves", of the PGF manual.


An example:

\begin{tikzpicture}
  \node [draw,fill,circle,minimum size=.15cm] (r) at (0,0) {} ;
  \path (r) edge[loop above] node[left=1pt] {3} (r);
  \path (r) edge[ out=140, in=50
                , looseness=0.8, loop
                , distance=2cm, ->]
            node[above=3pt] {4} (r);
\end{tikzpicture}

This produces the picture

Two loops of different heights.

share|improve this answer
    
Thank you very much. – user1553 Dec 26 '10 at 19:05

Your Answer

 
discard

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