5

Initially I wanted to open a question:

How to get (more) text on a page with large floats?

But of course the topic at hand has been covered way more many times than google can list on one page. (some links: /1, /2, and /3). After searching around, I started adding the following lines in my MWE which essentially solved the problem in the MWE:

\renewcommand\textfraction{.1}
\setcounter{totalnumber}{5}
\renewcommand{\floatpagefraction}{.8}

Picture for MWE

enter image description here

So I am in the situation where my MWE works perfectly while my real document does not. The relevant page in my real document looks like this:

enter image description here

=> I am wondering, if I play around with the values mentioned earlier, could I break something? Are there values which I should not use for textfraction, totalnumber or floatpagefraction?

MWE

\documentclass[
a4paper
]{scrreprt}

\usepackage{ lmodern, }

\usepackage[% paper=a4paper, left=3cm,% right=2cm,% top=3cm,% bottom=2cm,% headheight=1.5cm,% headsep=1.5cm,% ]{geometry}

\usepackage[T1]{fontenc} \usepackage[utf8]{inputenc}

\renewcommand\textfraction{.1} \setcounter{totalnumber}{5}

\begin{document}

\begin{figure}[htbp] \centering \fbox{\parbox[c][8cm]{0.4\linewidth}{Height8cm}} \caption{Test} \label{fig:Test1} \end{figure}

Short text. Blahblah. Short text. Blahblah. Short text. Blahblah.

\begin{figure}[htbp] \centering \fbox{\parbox[c][10cm]{0.4\linewidth}{Height10cm}} \label{fig:Test2} \caption{Another test} \end{figure}

Third short text. Blahblah. Short text. Blahblah. Short text. Blahblah.

\begin{figure}[htbp] \centering \caption{Test} \fbox{\parbox[c][6cm]{0.4\linewidth}{Height6cm}} \label{fig:Test3} \end{figure}

\end{document}

David Carlisle
  • 757,742
henry
  • 6,594
  • I wouldn't set \textfraction to anything less than 0.2. If less than 20% of the page is available for text, the little amount of text that can fit on the page tends to look totally forlorn, and the likelihood that the text on that page actually contains a call-out to the figure(s) and table(s) on that very page is rather low. Put differently, it's advisable to create a floats-only page if the floats take up at least 80% of the height of the text block. – Mico Jul 22 '14 at 08:34
  • @Mico Ok. Personally, I am totally fine with that, seeing how I primarily just want to avoid breaking anything or "hacking" LaTeX too much. Secondly, ... any clues on my "problem" by any chance? – henry Jul 22 '14 at 08:43

1 Answers1

3

If there was a "right answer" to this question the values would be fixed to that and not user set able. Basically you want to follow the advice in Frank's answer

How to influence the position of float environments like figure and table in LaTeX?

To comment on the values that you have set

\renewcommand{\floatpagefraction}{.8}

This makes it typically impossible to make a float page, so makes it quite likely that all figures go to the end. LaTeX will not issue a float page unless the page is 80% full, so if you have two figures that are each say 60% of the page height, it can not output a single figure as that is not enough, it can not output two figures as that is too much and it never re-orders the figures so it is stuck and it will hold everything back until it gets to end of document or \clearpage where it will dump all the figures while ignoring these constraints.

Different values are suitable for different kinds of floats and different desired effects, you have just asked what values to avoid without saying what you are trying to achieve by changing the values.

David Carlisle
  • 757,742
  • First of, based on on your notes on this, I have commented the lines in the op out. I rather do this than tinker around with it. Hm, in regards to Frank's post: I think I am actually intending to influence the placement of text on a float page. But it probably results in the same I suppose. So that is it: I intend to get some text on the page I showed--I think it looks a bit empty and I do not want to make the figures anymore narrow than they currently are (0.9\linewidth). Initially they were at \linewidth but looked only a bit better. – henry Jul 22 '14 at 09:19
  • @henry float pages have no text, only floats. – David Carlisle Jul 22 '14 at 09:50