4

\tikz\panda from tikzlings works as a tag for an equation, but if I insert a \label in the equation I get an error. MWE:

\documentclass[11pt,american]{beamer}
\usepackage{tikzlings-pandas}

\begin{document}

\begin{frame}{Pandas}
\begin{equation}\text{The apple-eating Panda}\tag{\tikz\panda[scale=0.15,body=gray];}\label{pandas}
\end{equation}
\end{frame}

\begin{frame}{More Pandas}
As we saw in \eqref{pandas}:
\begin{equation}\text{The not-eating Panda}\end{equation}
\end{frame}

\end{document}

Error:

! Undefined control sequence.
\tikz@deactivatthings ->\def ;
                         {\tikz@nonactivesemicolon }\def :{\tikz@nonact...

Is there some way of making the \label-\eqref mechanism work together with tikzlings as \tag?

1 Answer 1

12

endangered species must be protected:

\documentclass[11pt,american]{beamer}
\usepackage{tikzlings-pandas}

\begin{document}

\begin{frame}{Pandas}
\begin{equation}\text{The apple-eating Panda}\tag{\protect\tikz\protect\panda[scale=0.15,body=gray];}\label{pandas}
\end{equation}
\end{frame}

\begin{frame}{More Pandas}
As we saw in \eqref{pandas}:
\begin{equation}\text{The not-eating Panda}\end{equation}
\end{frame}

\end{document}

enter image description here

1
  • 1
    +! for the sentiment in the first sentence. Commented Mar 3, 2021 at 23:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .