I'm not very experienced with LaTeX and I'm having trouble when trying to define a macro to include some images. I want to do it this way because I'm trying to take notes using LaTeX and I need to type it quickly. The macro is:
\newcommand{\capeps}[3]{\begin{figure}[h]
\begin{center}
\includegraphics[width=.9\linewidth]{./figures/#1.eps}
\caption{#2}
\label{fig:#3}
\end{center}
\end{figure}}
but I can't make it recognize the label. Do you know what's the problem with this?
centerenvironment with\centering. Welcome to TeX.sx! – cgnieder Oct 26 '12 at 19:06\ref? For\capeps{xxx}{yyy}{zzz}it has to be\ref{fig:zzz}and not just\ref{zzz}. – Qrrbrbirlbel Oct 26 '12 at 20:34