4

I hope this is not a duplicate; I tried to search around and didn't find anything, but perhaps I used the wrong keywords. I'm using Plain TeX and have the following defined:

\newskip\hugeskipamount
\hugeskipamount=24pt plus 8pt minus 8pt
\def\hugeskip{\vskip\hugeskipamount}

This is all fine and well, however sometimes when I have

A
\hugeskip
B

and B starts a new page, the vskip disappears at the bottom of the page, and the page becomes all streched out, giving an underfull vbox. Is there a way to define hugeskip in such a way that if it turns up at the end of a page, it just functions like a vfill, i.e., there'll be a bit of a gap at the end of the page (which I find better than increased gaps between paragraphs). Thanks!

1
  • In addition to David Carlisle's excellent answer below, I figured out that you can also use \raggedbottom which also fixes other kinds of underfull hboxes by adding that extra space below. (But be careful of places you have put \goodbreak.)
    – marcelgoh
    Mar 26 at 18:27

1 Answer 1

9

Your question would have been clearer with an example but if I understand correctly

\def\hugeskip{\vskip\hugeskipamount\filbreak}

\filbreak is plain macro \vfil\penalty-200\vfilneg so normally it does nothing but if a page break happens at the penalty you get vfil at the bottom of the page, the \vfilneg is discarded before the next page starts.

1
  • Thank you for the quick response! This worked for me
    – marcelgoh
    Mar 26 at 1:03

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .