Mark 要求在这里添加一些关于如何从 PDF 添加页面的内容。
(另请参阅 插入整个 PDF)
所以,嗯,这是第一次尝试。
假设我们有一个 2 页的 PDF……我刚做了一个。这是它的 2 页视图:
我正在使用其中一个测试文件,该文件包含华丽的章节标题,以及 GEN、LEV(有玫瑰的那页)和 MRK 的单页“书”,其中 MRK 有 2 页:
-
将文件放入项目的 figures 目录(在 linux 上是 ~/Paratext9Projects/PROJID/figures)。这个简单的步骤意味着当你在足够多的计算机上通过 Paratext 进行了足够多次的 send+receive 之后,该文件也可以供其他人甚至你的其他计算机使用。
-
打开 PTXprint 上的 figures 选项卡,点击“Add”

-
选择 PDF 文件
-
设置锚点引用。在这个例子中,我在一个测试文件中工作,该文件在 LEV 1.7 和 MRK 1:1 之间没有任何内容。我将告诉它在 LEV 1.7 之后包含图像。

-
通过在 extras 框中输入 page=1 来选择我们想要的 PDF 文件页面:

-
设置大小……我们这里需要页码,所以我将选择 Page (in Margins)

-
按打印,哦,看,它在那里:
-
让我们添加另一页,这次不带页码……所以添加图像,选择文件和页码。嘿,这很奇怪,为什么 page=1 还在那里?(@mjpenny)? 设置锚点,再次使用 LEV 1.7,将页面大小设置为 Page (to Edge) 然后按打印……
哦。没有图片。
似乎虽然 TeX 可以处理同一引用中“同一图像”的多个副本(即使是第 2 页而不是第 1 页),但用户界面不想为我们这样做。它只是忽略了第二页。
让我们将第一页的锚点设置为 LEV 1.6,第二页设置为 LEV 1.7(记住在给出锚点引用时使用点号,而不是冒号!)
太棒了! 我们有了两页。需要注意的事项:
- 当你这样做时,这两页被视为单独的图像。
- 如果我们选择
Page (to Margins),那么网格线以及页眉和页脚会被包含在内;如果我们说 Page (to Edge),它们则不会。
- 如果你仔细看,你会发现 LEV1.6 上也有玫瑰,以及整页图像。XeTeX 不介意锚定在一个经文上的多个图像,只是用户界面变得挑剔,没有写入文件。
- 镜像和旋转有效(尽管镜像可能不是对文本最友好的操作!)
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:
-
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.
-
Open the figures tab on PTXprint and click on ‘Add’

-
Select the PDF file
-
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.

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

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

-
Press print, oh, look there it is:
-
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:
- The two pages are treated as separate images when you do it this way.
- 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.
- 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.
- Mirroring and rotation work (though perhaps mirroring isn’t the nicest thing to do to text!)
机器翻译自 English