2

My question appears to be the same as Enforce strict margin boundaries Yet, my problem is more than just left and right margin issues. Like the other poster, I'm working to finalize my dissertation and have a 600+ page document.

The additional issues that are being encountered are bottom margin violations. This happens when a line has lowercase letters such as p and g and the bottom portion goes outside the bottom margin.

The second issue is that sometimes an equation is the bottom line and completely violates the margins. The third unaddressed issue is that sometimes the right margin is violated just a little bit.

I agree that these issues are minor and will not detract from the overall look of the document, yet graduate office personnel love to make a practice out of being zealots for margins because it is easy to check and there is a clear dividing line.

I used the use package command: \usepackage[letterpaper,showframe]{geometry} to display the margins.

bottom margin violation due to letters bottom margin violation due to an equation enter image description here

user3780514
  • 325
  • 1
  • 11

1 Answers1

4

The depth of the last box on a page is allowed to stick into the bottom margin by at most \maxdepth, see Ulrike's answer. The rationale is to have the same bottom base line of facing pages.

\maxdepth applies to all boxes at the bottom of a page including simple text lines and math equations.

The left and right margins can be violated by a feature called "protruding", see package microtype. The idea is that some glyphs (with smaller black pixel percentages) stick a little bit into the margin. The effect should be a visually smoother appearance of the margin.

Some letters, especially in italics fonts, like the italics "f", stick out of its character bounding box. This should optimize the inner-character spacing. The price is that such a glyph can stick into the right margin.

Overfull \hbox and \vbox and warnings should be resolved. Otherwise the overfull boxes can stick into the right and bottom margin by larger amounts.

Heiko Oberdiek
  • 271,626
  • Thanks for the answer and great information. Ulrike's answer was right on although I needed to figure out which \usepackage \maxdepth was part of. This link helped me see how to properly set it. https://tex.stackexchange.com/questions/179718/how-to-have-a-precise-control-on-the-size-of-each-page – user3780514 May 07 '18 at 14:03
  • I used showframe to see a lot of the overfull \hbox and \vbox warnings and resolve them. Most of them were figures that violated the margins. I still have a long list of them and I'm not sure what is causing the remaining warnings. Do you have any advice on how to troubleshoot and resolve overfull box warnings? – user3780514 May 07 '18 at 14:05
  • @user3780514 Either use class option draft (standard classes) or use \setlength\overfullrule{5pt}. Then a black bock appears at the right side of overfull \hboxes. – Heiko Oberdiek May 07 '18 at 16:59
  • I also found this discussion useful for understanding \fussy and \sloppy... https://tex.stackexchange.com/questions/241343/what-is-the-meaning-of-fussy-sloppy-emergencystretch-tolerance-hbadness – user3780514 May 08 '18 at 19:01
  • +1 Good to know. "The rationale is to have the same bottom baseline of facing pages." Is that not also true/possible if \maxdepth is zero? – Dr. Manuel Kuehner May 15 '18 at 21:45
  • 2
    @Dr.ManuelKuehner Compare a last line without descenders (e.g. lacus vel est. Curabitur consectetuer.) with a last line with descenders (e.g. adipiscing quis,). – Heiko Oberdiek May 16 '18 at 04:39