18

I'm updating my CV, which is written by modifying this template. I have always been very happy with the result, but now I'm getting a Too many unprocessed floats error.

For those who do not want to have a look at the template, it basically works like this. In the preamble I have a command

\newcommand{years}[1]{\marginpar{\scriptsize #1}}
...
\begin{document}
\reversemarginpar

which one then uses like

\section*{Seminars}
\years[2005]Blah blah...
\\
\years[2007]Blah blah blah..

The problem is, when I insert the 10th item, I get the Too many unprocessed floats error.

Inserting a clearpage is not an option, since it would just leave half page empty. Also, doing a major change to the CV, like switching to another template or using a CV class is not an option either. I have tried many different ways to write my CV; it always takes time to switch, and I need to compile it soon. Moreover I'm very happy with this template.

Is there a way to increase the number of floats that LaTeX can handle?

Andrea
  • 4,127
  • Remark, in your "MWE" you missed a backslash before the command name, see this https://tex.stackexchange.com/q/29463/250119 – user202729 Oct 26 '22 at 05:25

3 Answers3

16

The package morefloats doubles the number of floats that can be handled.

Stefan Kottwitz
  • 231,401
2

You can replace the definition of the \years command by something like the following:

\newcommand{\years}[1]{\makebox[0pt][l]{\hskip-.6in{\scriptsize #1}}}

If you need to introduce line breaks within the years, something slightly more complicated is needed. Then you might want to consider using \parbox and \raisebox in the definition of the \years command, but this shouldn't usually be necessary.

Since you are not using any floats anymore, LaTeX will stop complaining.

Thorsten
  • 12,872
aleph0
  • 21
2

I did not know about the morefloats package, but I'll try using it to solve my problem.

To solve that problem there is another solution, but in theory not a very good one although it does work great:

Just use [H] instead of [htbp] as float specifier. What happens is that LaTeX stops freaking out with too many unprocessed floats.

Stephen
  • 14,890
Splashy
  • 5,915
  • "However, if your floats can’t be placed anywhere [e.g. because it is just too large for the page], extending the number of floats merely delays the arrival of the inevitable error message." (http://ctan.org/pkg/morefloats) – Stephen Jan 07 '12 at 10:24