[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: (Re)setting page and footnote numbers
From: |
Lennart Jablonka |
Subject: |
Re: (Re)setting page and footnote numbers |
Date: |
Mon, 28 Aug 2023 15:14:41 +0000 |
Quoth Pippo Carmona:
I am currently making a compilation of technical essays by merging
multiple pdfs made with Groff.
You can concatenate the troff output before post-processing.
{
troff -Tpdf a
troff -Tpdf b
} | gropdf >all.pdf
However, one problem that I have is that
each chapter is made independently, making each chapter start at page
1. So when I merge the chapters, the page number reverts to 1 at the
beginning of each.
How can I set the page number of a specific file into a set number and
increment from thereon? I have tried the man macro -rPnnn but it won't
work with my document.
It works with man because man does that.
.\" …
. if r P \{\
. ie (\n[nl] = -1) .pn 0\n[P]
. el .nr % 0\n[P]
. \}
.\" …
If you aren’t using man, you can do it yourself. For every
document, execute something like
.if r P .pn \nP
at the start.
I haven't found the solution to the above so I made another document with all
the chapters in one .ms file.
Even if you process the whole text at once, it need not be in one
file. See the .so request.
The problem with this is that all footnote
numbers increment until the end. So, if chapter 1 ends with 18
footnotes, the footnotes of chapter 2 proceeds with 19. I want each
chapter's footnotes to start with 1. Can this be accomplished?
You can provide your own footnote markers.