Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Endfloat - File ended while scanning use of \next

3,751 views
Skip to first unread message

Jarle Tufto

unread,
Aug 26, 1995, 3:00:00 AM8/26/95
to
I'm trying to use the endfloat package to have figures and
tables floated to the end of the manuscript. It appear to
work with tables but the following happends when I include a
figure in the text:

(POLLEN.fff))
Runaway argument?
! File ended while scanning use of \next.
<inserted text>
\par
<*> &latex POLLEN.TEX

For some mysterious reason endfloat appear to ignore the
\end{figure} command and include the rest of my document in
the .fff file. The preamble looks like this:

\documentclass[12pt,a4paper]{article}
\usepackage{amsmath}
\usepackage{natbib}
\usepackage{endfloat}
\usepackage{array}
\renewcommand{\baselinestretch}{1.6}
\begin{document}

I have tried to move things around and delete various parts
of of the text around the figure without much success.

Any suggestions?

Jarle Tufto

Alain Kessi

unread,
Aug 27, 1995, 3:00:00 AM8/27/95
to jtu...@nvg.unit.no
jtu...@nvg.unit.no (Jarle Tufto) wrote:
>For some mysterious reason endfloat appear to ignore the
>\end{figure} command and include the rest of my document in
>the .fff file.

Most likely this is not a problem with endfloat itself. It does sound like
you forgot to close a brace, i.e., there is a "{" without corresponding
"}" at some point in your file. Unfortunately, LaTeX lists "\next" as
being the command which doesn't have a closing brace. You probably don't
have this command in your file at all, but more likely some command that
contains it implicitely. I'd suggest doing things the other way around if
you can't find where you're missing a closing brace: Start with an empty
document with just your preamble and gradually add one float (maybe
simplified to contain basically nothing), then some text, etc. and
compile every time to see when problems set in. (It's often more
convenient to start with a short file you know works than with a long
one you know doesn't work.)

I hope this works! Best regards,

Alain

--
Alain Kessi (alain...@psi.ch)
Paul Scherrer Institut, Zuerich, Switzerland


J.Goldberg

unread,
Sep 4, 1995, 3:00:00 AM9/4/95
to
Given the way news travels, I haven't seen the original post,
only the reply (quoting the original).

In article <41qrp2$n...@pss100.psi.ch>, Alain Kessi <alain...@psi.ch> writes:
|> jtu...@nvg.unit.no (Jarle Tufto) wrote:
|> >For some mysterious reason endfloat appear to ignore the
|> >\end{figure} command and include the rest of my document in
|> >the .fff file.
|>
|> Most likely this is not a problem with endfloat itself. It does sound like
|> you forgot to close a brace, i.e., there is a "{" without corresponding
|> "}" at some point in your file. Unfortunately, LaTeX lists "\next" as
|> being the command which doesn't have a closing brace. You probably don't
|> have this command in your file at all, but more likely some command that
|> contains it implicitely.

Endfloat uses next in its verbatim-like reading of the figure. Having
not seen the original posting I don't know that the actual error message
was. The odd thing is that each \next should be completed by an end of line.
(TeX's ^^M). When reading a figure or table, \next is redefined after
each line as effectively either get next line or as write out \end{figure}
(or table) to the .fff or .ttt file.

Obviously endfloat has failed to see the \end{figure}, but I don't know
why. An erroneous { shouldn't cause such a problem.

I would very much like to see the file that resulted in the error. It
may be a "bug" in endfloat. It may be an "undocumented limitation". Either
way, I should fix either the code or the documentation for the next release.

(I have been sitting on a quick fix release that provide some beginings
of hooks for allowing other types of end material (and an example that
really works with sidewaystable and sidewaysfigure from rotating) for
a while thinking I was going to do more work, but I think that I will release
that intermediate version soon.)

|> I'd suggest doing things the other way around if
|> you can't find where you're missing a closing brace: Start with an empty
|> document with just your preamble and gradually add one float (maybe
|> simplified to contain basically nothing), then some text, etc. and
|> compile every time to see when problems set in. (It's often more
|> convenient to start with a short file you know works than with a long
|> one you know doesn't work.)

This is always good advice. And if the bug is in endfloat (I wouldn't
be really surprised), but it would help isolate the bug.

-jeff

--
Jeffrey Goldberg
Email: J.Gol...@Cranfield.ac.uk
WWW: <http://WWW.Cranfield.ac.uk/public/cc/cc047/>

Jarle Tufto

unread,
Sep 13, 1995, 3:00:00 AM9/13/95
to
cc...@Cranfield.ac.uk (J.Goldberg) wrote:
> In article <41qrp2$n...@pss100.psi.ch>, Alain Kessi <alain...@psi.ch> writes:
> |> jtu...@nvg.unit.no (Jarle Tufto) wrote:
> |> >For some mysterious reason endfloat appear to ignore the
> |> >\end{figure} command and include the rest of my document in
> |> >the .fff file.
>
> I would very much like to see the file that resulted in the error. It
> may be a "bug" in endfloat. It may be an "undocumented limitation". Either
> way, I should fix either the code or the documentation for the next release.
>

Okey, I've been able to track down what causes the "bug"...
Here is a small file that produce the error:

\documentclass{article}
\usepackage{endfloat}
\begin{document}
\begin{figure}
The figure
\caption{This is a test}
\end{figure}
\end{document}

I indented figure and table environments to make my .tex file more readable and this
appeared to upset endfloat. Everything worked if I didn't use endfloat or didn't
indent the figure environment.

Jarle Tufto

J.Goldberg

unread,
Sep 14, 1995, 3:00:00 AM9/14/95
to
In article <4362qv$b...@doffen.uninett.no>, Jarle Tufto <jarle...@nina.nina.no> writes:

|> Okey, I've been able to track down what causes the "bug" [in endfloat]


|> Here is a small file that produce the error:
|>
|> \documentclass{article}
|> \usepackage{endfloat}
|> \begin{document}
|> \begin{figure}
|> The figure
|> \caption{This is a test}
|> \end{figure}
|> \end{document}
|>
|> I indented figure and table environments to make my .tex file more readable and this
|> appeared to upset endfloat. Everything worked if I didn't use endfloat or didn't
|> indent the figure environment.

I have already answered this by mail. It is a ``limitation'' of endfloat.
the "\end{figure}" must be at the begining of the line (and there may
not be spaces after it either). I will make this clearer in the documentation.
I don't expect this fixed for a while. It would take a rewrite of the part
of the package I understand the least :-(

0 new messages