2

Consider the following LaTeX Code:

\documentclass[a4paper]{amsart}
\usepackage{lipsum}
\begin{document}
    \lipsum
\end{document}

The generated PDF has US Letter, Portrait (8.50 × 11.00 inch) as its letter size, but I specifically requested it to be a4paper. However, adding \usepackage{graphicx} fixes the issue:

\documentclass[a4paper]{amsart}
\usepackage{graphicx}
\usepackage{lipsum}
\begin{document}
    \lipsum
\end{document}

The paper size is now A4, Portrait (8.27 × 11.69 inch).

Questions

  1. What is causing the effect described above?
  2. Should the paper size be changed by adding \usepackage{graphicx} or is there a more standard way to do so?
3
  • 1
    Welcome to TeX.SX! Actually, I cannot reproduce this problem. If I use \documentclass[a4paper]{amsart}, I get a PDF with 210 x 297 mm which is A4. The option a4paper is also documented in the package documentation. Anyways, the paper size can also be set using the package geometry. The package graphicx is not meant for this. Aug 8, 2022 at 22:58
  • @JasperHabicht this is by design (including graphicx feature) Aug 8, 2022 at 23:00
  • This is in a way a duplicate of tex.stackexchange.com/questions/524987/… The answer given there also provides some other options that will help change the paper size. Aug 9, 2022 at 1:07

1 Answer 1

5

This means that you have the site default set to US Letter, [a4paper] sets the text block for typesetting to A4 but can not (or at least does not) set the pdf media size until it knows which back end is in force, typically graphicx or hyperref or geometry will force a back end option. If you are loading one just for this, geometry is perhaps the most natural.

You must log in to answer this question.

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