I want to produce a document consisting of a single tikZ figure.
Code: Select all
\documentclass{article}
\usepackage{tikz}
\begin{document}
\pagestyle{empty}
\centering
\begin{tikzpicture}
\draw (0,0) arc (0:360:3cm);
\draw (0,0) arc (0:360:2cm);
\draw (-2,0) arc (0:360:2cm);
\draw (-1,-1) arc (0:360:2cm);
\draw (-1,+1) arc (0:360:2cm);
\end{tikzpicture}
\end{document}
I want the page to just fit the figure. (That is, the size of the page is set to the size of the figure.) I know I can use the geometry package to manually set the page size, but I am looking something automatic. Does anyone have an idea on how the page size can be automatically set to the size of the figure inside it?
Thanks.