Footnotes – How to Handle Very Long Footnotes Causing Page Breaks

bigfootfootnotes

If a document has very long footnotes close to each other in the main text, LaTeX start to compensate for this by breaking the page (see the first picture below).

I am grateful that TeX makes an effort to put footnotes close to the corresponding mark, but no thank you, TeX, this is too much. No matter what, it should not break the page, nor make the paragraph skips longer (which is almost as ugly) or use any of its other usual, dirty tricks; I prefer having the footnote five pages after the mark if that is what it takes. Can someone find a way to make TeX stop breaking the page like this?

I tried experimenting with both bigfoot and interfootnotelinepenalty=0, which changed the input, but did not remove the problem. Furthermore, bigfoot caused the nightmare shown on the second picture below. Notice that the footnotes run out of the page itself.

Note that memoir is not the problem either; change to article and load geometry, and exactly the same happens. Also, the A5 format is not the issue either; it just makes the problem even worse than when using A4.

A MWE:

\documentclass[a5paper]{memoir}

\usepackage{lipsum}
%\usepackage{bigfoot}
%\interfootnotelinepenalty=0

\begin{document}
    \lipsum[1]\footnote{\lipsum[1-10]}
    \lipsum[1]\footnote{\lipsum[1-15]}
    \lipsum[1]\footnote{\lipsum[1-10]}
    This needs a footnote\footnote{\lipsum[1-10]}, and it is very necessary in order not to cause confusion.
\end{document}

The output:

enter image description here

The output with bigfoot:

enter image description here

Best Answer

You could try to change \floatingpenalty in \@footnotetext (globally or locally). But imho it would much saner to shorten the footnotes.

\makeatletter
\long\def\@footnotetext#1{\insert\footins{%
    \reset@font\footnotesize
    \interlinepenalty\interfootnotelinepenalty
    \splittopskip\footnotesep
    \splitmaxdepth \dp\strutbox \floatingpenalty 100 %<---
    \hsize\columnwidth \@parboxrestore
    \protected@edef\@currentlabel{%
       \csname p@footnote\endcsname\@thefnmark
    }%
    \color@begingroup
      \@makefntext{%
        \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}%
    \color@endgroup}}

Edit 2017

As packages like footmisc can change \@footnotetext it is probably better to patch the definition (after all packages which could change the definition again have been loaded):

  \usepackage{etoolbox}
  \makeatletter
   \patchcmd\@footnotetext{\@MM}{100}{}{\fail}
  \makeatother

Instead of a fix value of 100 one could also use a command or a counter which could be redefined locally.

Related Question