Skip to main content

The PreTeXt Guide

Section 30.9 Page Number Fidelity

If you produce a “print” PDF, perhaps as a precursor to producing a physical book, the page numbers may be important to you and your readers. Thus, you may desire that an “electronic” PDF have faithful page numbers. And together we might consider this a canonical numbering of the pages of your project. (Long-term we hope to migrate these page numbers into other formats, such as braille. See GitHub #1020 4 .) Fundamentally, a PDF destined to become a physical book will be built with “two-sided” pages, while an electronic PDF will have “one-sided” pages. The two-sided version will often leave a page blank at the end of a division (e.g. parts or chapters), so a subsequent division begins (“opens”) on an odd-numbered page, also known as a recto page. We have publisher options for print versus electronic (Subsection 44.3.1), which subsequently provide (different) defaults for “sidedness” (Subsection 44.3.2).
Suppose you wish to have your electronic (one-sided) PDF have identical pages (i.e. identical content) with identical page numbers as your print (two-sided) PDF?
First decision point is: what do your cross-references look like? If every cross-reference looks like Section 5.2, then presumably a reader of print (or embossed braille) can locate the target. But if you have used a cross-reference that looks like Fermat's Theorem then you have exhibited a preference for electronic formats at the expense of readers of physical formats. To remedy this, we allow for the automatic insertion of page numbers as part of every cross-reference (see Subsection 44.3.6). But all these page numbers will increase the length of your physical version and pages will never match up. So that your cross-references are workable in all output formats, or you should elect to have page numbers in every cross-reference, for each PDF produced.
Now a further complication is that a two-sided version will always start some larger divisions (parts, chapters, appendices) on an odd-numbered page, the recto page (versus the verso page). This sometimes requires an additional blank page on the verso side. But a one-sided version has no need for this practice, so the two-sided version will eventually have different (larger) page numbers on the identical content. The solution is to use a publisher option, which is only effective when a one-sided version is produced, that creates these blank verso pages or skips the page numbering ahead by one when there would have been a blank page. The result is that major divisions will always open on an odd-numbered page, matching the two-sided version. See Subsection 44.3.3 for details. (Note that this is not the default and so must be a conscious choice.)
You have attempted of activities on this page.
github.com/PreTeXtBook/pretext/issues/1020