When editing a LaTeX document, I prefer having the source on one display and a live preview (by means of latexmk -pvc or similar) on another display. When the secondary display can be physically rotated, I do -- this allows me to show the preview at original size or even larger. But if the display cannot be rotated, the font size usually becomes too small when a (portrait) document is scaled down to fit the screen.

I'm looking for a way to adapt the page geometry for screen preview while preserving the \textwidth (to make sure that figures still are rendered "somewhat correctly"). How to tell the geometry package to:

  • adjust the paperwidth so that the width is maintained as is, adding a small margin
  • adjust the paperheight to a given aspect ratio
  • remove (or hide) headers and footers

Is there a package that encapsulates this, perhaps including a check if this "screen" mode is active?

Related: Optimising for on-screen viewing.

1 Answer 1


It turns out that the geometry package accepts length parameters and also supports the calc package, as noted in the manual. This gives the following options:


This uses 1em as margins, an aspect ratio of 5:4 (=1 / 0.8), hides the footer and uses minimal space for the header. The lines may become overly long and difficult to digest, so


can be used to generate shorter lines. (I don't know how to enter a "three column" mode.)

These settings are now optimal for text, but the preview of figures might be distorted. I haven't found a package that encapsulates the layout setting -- would such a package be useful?

You must log in to answer this question.

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