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.

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

This may seem a bit trivial, but I am writing TikZ code with an enormous number of unlabelled nodes. It frustrates me that I have to type {} at the end of every node declaration. Is there some straightforward way to avoid having to type this? Omitting the {} gives a compilation error: A node must have a (possibly empty) label text.

share|improve this question
up vote 10 down vote accepted

The {} are part of the internal used syntax and can't be avoided (just replaced by \bgroup \egroup, but that doesn't help you).

If your \nodes don't have any content and size and are only used to store the coordinates, then I would use \coordinate instead (or \path coordinate). It is basically a \node without content. IIRC it uses \node [..] {}; internally.

Alternatively just write your own macro which inserts the correct \node syntax itself.

share|improve this answer
Such a macro could be something as simple as \def\nod [#1]{\node[#1] {} }. You can then write \nod [draw=red]; instead of \node[draw=red] {};. – Jake Aug 16 '11 at 10:26
Thanks Jake, just what I needed. – Jamie Vicary Aug 16 '11 at 10:47

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.