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

I'm rigging up some code so that I get the references cited on a slide displayed directly in the footline of my beamer presentation, and I've run into an error that mystifies me. The code I have (which works) is this:


\defbeamertemplate{footline}{footline refs}{
    \hbox{\begin{beamercolorbox}[wd=\paperwidth,dp=1ex]{refs in foot}%
\setbeamertemplate{footline}[footline refs]

But if I want each reference on a separate line, and change \cite to be:


The compilation fails with a capacity exceeded error:

! TeX capacity exceeded, sorry [main memory size=3000000].
<argument> ...le }\framesubtitle }\framesubtitle }
                                                  \framesubtitle }\framesubt...

I find it a bit odd that having a space be the separator works fine but newlines explode (same thing happens with \newline). Does someone know what's wrong (or a better way to do the newline-separated list thing I want to do?

share|improve this question
up vote 2 down vote accepted

is an accident waiting to happen.



or safer


(Untested as no runnable example supplied)

share|improve this answer
\protected@xdef did the trick. \def\cite#1{\g@addto@macro\framerefs{\interframerefs#1}\gdef\interframerefs{\\}}‌​ seems to have different semantics, as with that I get a \newline before the first cite (which LaTeX complains about: "There's no line here to end."). Thanks for the help! – arnsholt Oct 15 '12 at 16:53

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.