0 votes

Mark asked that there be something here about how to add pages from a PDF.
(see also inserting an entire PDF)
So, urm, here’s a first go.
Let’s assume we have a 2 page PDF… I’ve just made one. Here it is in 2 page view:

I’m using one of the test files, which has fancy section headers and single page ‘books’ for GEN, LEV (the page with roses), and MRK, which has 2 pages:

  1. Put the file into the project’s figures directory (~/Paratext9Projects/PROJID/figures on linux). This simple step means that the file becomes available to others too, or even your other computers, when you’ve done send+receive with Paratext enough times on enough computers.

  2. Open the figures tab on PTXprint and click on ‘Add’
    image

  3. Select the PDF file

  4. Set the anchor reference. For this example, I’m working in a test file that has nothing between LEV 1.7 and MRK 1:1. I’ll tell it to include the image after LEV 1.7.
    image

  5. Select the page of the PDF file that we want, by entering page=1 in the extras box:
    image

  6. Set the size… We want page numbers here, so I’ll select Page (in Margins)
    image

  7. Press print, oh, look there it is:

  8. Lets add the other page, this time without page numbers… so Add image, select the file, and the page number. Hey, that’s odd, why is page=1 still there? (@mjpenny)? Set the anchor, LEV 1.7 again, set the page size to be Page (to Edge) And hit print…

Oh. No picture.
It seems that while TeX can cope with multple copies of ‘the same image’ (even if it is page 2, not page 1) on the same reference, the user interface doesn’t want to do that for us. It just ignores the second page.

Let’s set the anchor for the first page to LEV 1.6 and the second to LEV 1.7 (remember to use a dot, not a colon when giving the anchor references!)

TaDa! we have both pages. Things to notice:

  1. The two pages are treated as separate images when you do it this way.
  2. If we select Page (to Margins), then the grid lines, and page headers and footers get included, if we say Page (to Edge) they don’t.
  3. If you looked carefully, then you’d see that there’s a rose on LEV1.6 as well as the full page image. XeTeX doesn’t mind multiple images anchored to one verse, it was just the user interface getting uppity and not writing the file.
  4. Mirroring and rotation work (though perhaps mirroring isn’t the nicest thing to do to text!)
PTXprint by (699 points)
reshown

3 Answers

0 votes

Great instructions–I’m sure there are cases where this approach would be necessary. But would something like PDFSAM (PDF Split and Merge) be just as effective? And perhaps easier? It is ‘post production’, so loses something in that respect… https://pdfsam.org/, for what it’s worth.

by (613 points)

If you are suggesting that PDFSAM could be used to make separate PDFs and then they get pulled in as individual images, well, yes, but typing page=3 seems simpler to me.

If you are suggesting that PDFSAM could insert pages as a post-production step yes, I’m sure it could, but the crop-marks and acurate page numbering would be lost.

I’ll also add that there is at least one other way of inserting an entire PDF into the output, (while preserving page numbering and crop-marks), but it gets more TeX-nical.

Edit: The method is here: inserting an entire PDF

0 votes

For post production addition or removal of pages, or cropping, PDFarranger on Linux is great.

by (173 points)
0 votes

My general attitude to post-production steps is to avoid them or make them fully automatic. That way, when my valuable human-time is not wasted, just computer-time, when some other human says ‘just this little change’. Thus PDFarranger won’t get my vote for a post-production tool, but the postproduction options in PTXprint do, (as they’re implicit in hitting Print).

Are there any particular options you’d like to see PTXprint add to its post-production steps? Or are you just suggesting PDFarranger in general?

by (699 points)

Related questions

0 votes
2 answers
+1 vote
0 answers
PTXprint Oct 9, 2023 asked by DG (699 points)
0 votes
19 answers
0 votes
6 answers
Welcome to Support Bible, where you can ask questions and receive answers from other members of the community.
Every day they continued to meet together in the temple courts. They broke bread in their homes and ate together with glad and sincere hearts, praising God and enjoying the favor of all the people. And the Lord added to their number daily those who were being saved.
Acts 2:46-47
2,607 questions
5,344 answers
5,034 comments
1,417 users