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

According to the TikZ manual I can use name= to assign a label to the drawings, but when I do the following:

\draw [ blue, thick, name=e1]  (10pt,10pt)  ellipse   (50pt and 30pt);
\node (red,above) at (e1.north) {E1};

I get an error message that e1 is not defined. What am I doing wrong?

My second question is where can I find a concise syntactical representation of TikZ's commands?

share|improve this question

You can only name nodes, not arbitrary parts of a drawing. In your example, if you wanted to be able to refer to the ellipse by name, you'd need to create it as a node instead of a plain ellipse. Try replacing your \draw command with this:

\node[draw=blue,ellipse,name=e1,minimum width=100pt,minimum height=60pt] at (10pt,10pt) {};

To address the second part of your question, I know of no better documentation of TikZ than the PGF manual itself. I've never heard of a short "cheat sheet" that briefly lists TikZ commands along with reminders of their syntax, if that's what you're looking for. Although it might be out there somewhere, at least for the most commonly used ones. You could probably create such a quick reference by extracting lines from the PGF documentation.

share|improve this answer

It is not a precise answer to your second question, but did you try the TeXample website? It contains a lot of examples (including source code) for doing all sorts of nice things with TikZ. In my experience, the TikZ manual can be a bit overwhelming at first glance. So if you are looking for doing something specific, you may be better off with adapting an example from this site.

share|improve this answer

Your Answer


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.