创建具有重叠文本/插图的固定布局 ePub
苹果公司有一种叫做“固定布局 ePub”的东西,它对于制作带有大量插图的儿童读物的 iBook(具有特定的文本和插图布局)特别有用。
我找到了解释如何制作固定布局 ePub 的指南(Threepress 是我找到的最好的教程),现在我可以制作固定布局 ePub 了。耶!
但是……如果你走进苹果商店并在其中一台 iPad 上启动 iBooks,你会看到儿童读物《Olivia》和其他书籍,其中的文字与插图重叠。文本不仅仅是图形的一部分——它是真实的、可选择的文本。
那么他们是怎么做到的呢?有人知道吗?你可能认为这些信息很容易找到,但到目前为止我还没有找到任何东西。必须有人知道,否则奥利维亚的书就不会存在。
(注意:这个问题是关于如何在 ePub 文件中编写实际的 HTML,该文件将显示与插图重叠的可选文本。我不想在某些文字处理器或页面设计应用程序中创建一本书,然后将其转换为 ePub。 )
Apple has something called Fixed Layout ePub, that's especially useful for making an iBook of a heavily illustrated children's book with a specific layout of the text and illustrations.
I have found guides that explain how to make a Fixed Layout ePub (Threepress is the best tutorial I found), and I can now make a Fixed Layout ePub just fine. Yay!
But... if you go into an Apple store and fire up iBooks on one of their iPads, you will see the children's book Olivia, and others, that feature text overlapping illustrations. The text is not just part of the graphic — it's true, selectable text.
So how did they do it? Anyone know? You would think this information would be easily locateable, but so far I haven't found a thing. Somebody must know, or the Olivia book wouldn't exist.
(Note: This question is about how to write the actual HTML in the ePub file that will show selectable text overlapping an illustration. I don't want to create a book in some word processor or page design app and then convert it to ePub.)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您在 XHTML 中找不到任何内容,则它可能位于 SVG 图像中。该图像可以内联插入 XHTML 或另一个文件中(在所有情况下都存储在 ePub 中,并从 XHTML 调用)。 iBooks 允许用户选择 SVG 图像中的文本。
我认为在你的情况下,文本和图像都包含在 SVG 文件中(它也可以存储位图图形)。
您还可以将位图放置为 JPEG/PNG,并使用绝对定位将文本放置在图像上(仅适用于固定布局 Epub)。
一般来说,当您有复杂的文本效果时,SVG 是 ePub 中的不错选择。 Apple 在其指南中推荐了它,iBooks 也很好地支持它。 Adobe Digital Editions 变得更加不可预测。
If you don't find anything in the XHTML, it could be in an SVG image. This image could be inserted inline in the XHTML or in an another file (stored in the ePub in all cases, and called from the XHTML). iBooks let the user select the text within an SVG image.
I think that in your case, the text and image are both contained in the SVG file (which can store bitmap graphics as well).
You can also place your bitmap as a JPEG/PNG, and place your text on the image with absolute positionning (only with Fixed Layout Epub).
Generally speaking, SVG is a good choice in ePub when you have complex text effects. Apple recommends it in its guides and iBooks supports it well. Adobe Digital Editions is more unpredictable with it.
文本实际上是使用 CSS 样式重叠到图像上的。看看奥利维亚这本书的内容,你就会明白它是如何完成的。另请查看 Threepress Consulting 博客上 Liza Daly 的解释。 http://blog. Threepress.org/2011/ 01/17/understanding-apples-fixed-layout-epubs/
The text is actually overlapped onto the image using CSS styles. A look into the guts of the Olivia book should show you how it's done. Also check out Liza Daly's explanations on the Threepress Consulting blog. http://blog.threepress.org/2011/01/17/understanding-apples-fixed-layout-epubs/