The problem can be replicated (I hope) with the following MWE:
\documentclass[twocolumn]{revtex4-1}
\usepackage{tikz}
\begin{document}
\begin{figure*}
\includegraphics[width=\linewidth]{example-image-a}
\end{figure*}
\clearpage
Some (or none) text
\end{document}
What happens is that the error Output routine didn't use all of \box255. []
is given, the image does not appear, and some blank pages are inserted instead.
The error doesn't show up changing most of the details in the above MWE. For example, it doesn't happen if:
revtex
is not used, or even if just thetwocolumn
option is not given- The package
graphicx
is used instead oftikz
to provide\includegraphics
figure
is used instead offigure*
.
The problem still appears if:
- Instead of
\clearpage
I use\FloatBarrier
, - The
\clearpage
command is before instead of after thefigure*
, revtex4
is used instead ofrevtex4-1
.
However, I need all of these elements in my actual document.
The case in which I experience the above is a long (around 10 pages) paper, written in revtex4-1
, in which I need to flush a long series of space-consuming wide-text figures before the bibliography. I however find myself completely unable to do so due to the above problem.
I need the tikz
package because the figures are partly built via tikz
commands.
I need the figures to be printed before the bibliography because if I don't explicitly impose so they end up scattered in the middle of various pieces of bibliography.
I tried a wide variety of combinations of solutions, but none worked. The best workaround I found was to have all the images printed after the bibliography, but that also is not acceptable because I also need to have an appendix after the bibliography, and I cannot have the images printed after also all the appendices, nor I want them scattered around the text of the appendices. Does anyone have an idea of what is going on here?
EDIT
David Carlisle's fix works on the above MWE. When used on a case with two figures, each composed of a pair of minipages, the dimensions of the second one are somehow changed with the fix. See the following new MWE:
\documentclass[twocolumn]{revtex4-1}
\usepackage{tikz}
\begin{document}
\begin{figure*}
\begin{minipage}[b]{\columnwidth}
\includegraphics[width=\columnwidth]{example-image-a}
\end{minipage}%
\begin{minipage}[b]{\columnwidth}
\includegraphics[width=\columnwidth]{example-image-a}
\end{minipage}%
\end{figure*}
\begin{figure*}
\begin{minipage}[b]{\columnwidth}
\includegraphics[width=\columnwidth]{example-image-a}
\end{minipage}%
\begin{minipage}[b]{\columnwidth}
\includegraphics[width=\columnwidth]{example-image-a}
\end{minipage}%
\end{figure*}
\clearpage
Some (or none) text
\end{document}