10

recognize this simple example:

\documentclass[]{article}
\usepackage[paperwidth=612.0pt, paperheight=792.0pt]{geometry}

\begin{document}
Hello World
\end{document}

I compiled it with pdflatex. Additionally I wrote this small Java-Programm (using the iText library):

PdfReader reader = new PdfReader("example.pdf");
Rectangle psize = reader.getPageSize(1);
System.out.println(psize.getHeight());
System.out.println(psize.getWidth());

The result:

Height: 789.041
Width: 609.714

Why is the paperwidth and paperheight different to the tex?

2
  • Welcome to TeX.sx! You don't have to sign with your name since it automatically appears in the lower right corner of your post. Oct 7, 2011 at 1:18
  • Thx for your info.
    – Dennis
    Oct 7, 2011 at 1:29

1 Answer 1

13

Because the unit is different. 1 point for TeX is 1/72.27 in, while many other programs use a PostScript point, which is 1/72 in. This is called a big point (bp) in TeX.

See also What are the various units (ex, em, in, pt, bp, dd, pc) expressed in mm?

3
  • I'm using TeX for some years now. I never heard about the unit bp. With bp the program returns the expected geometry. Thanks!
    – Dennis
    Oct 7, 2011 at 1:26
  • Besides a huge log file, are there other drawbacks of using pdf figures in "pt" and latex uses "bp"?
    – strauberry
    Aug 26, 2014 at 13:26
  • @strauberry I don't really see how this relates to the size of the log file. And I don't see how it is a drawback either, any more than specifying the size of the figures in centimeters or inches is a drawback -- it is a different unit, so you need to make sure to calculate the correct size. Aug 26, 2014 at 13:33

You must log in to answer this question.

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