07-23-2023, 02:45 AM | #1 |
Oracle Pig Keeper
Posts: 26
Karma: 5024
Join Date: Jun 2023
Device: Kindle Fire HD, Samsung Tab
|
Aligning Text Across Facing Pages
When producing a PDF or actual print book, it's easy to establish a baseline grid so that text on facing pages line up perfectly. How does one achieve this in HTML/CSS within an ePub?
I know that Apple Books and Kobo both require that text aligns this way on facing pages, but they provide no code examples on how to achieve this. During my testing, when both pages are just simple text, they do align. But when one page contains a chapter header at the top in a different font or size, no amount of minor spacing tweaks will achieve the desired goal. Is there an established way to do this easily? Are there any code samples out there on the subject you can point me to? Any help would be appreciated. Thanks |
07-23-2023, 06:04 AM | #2 | |
the rook, bossing Never.
Posts: 11,601
Karma: 87456643
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
Facing pages on epub?
You'd need a giant screen. Makes no sense on bulk of things used to read ebooks. I can't remember even seeing facing pages in reflowable ebooks in twenty years. Have you actually tried using facing pages on a 6″ to 8″ eink or on a 4″ to 6″ phone or an iPad mini? Quote:
I'd think only fixed layout will let you do what you ask and that won't work for most user-reading people as it needs 10″ or larger in landscape. Really real ebooks (not image based or PDFs) are single page and simulate two page up by using two columns. |
|
Advert | |
|
07-23-2023, 08:10 AM | #3 | |
Grand Sorcerer
Posts: 6,554
Karma: 84810789
Join Date: Nov 2011
Location: Tampa Bay, Florida
Device: Kindles
|
Quote:
Can you provides references to these requirements? |
|
07-23-2023, 09:41 AM | #4 |
the rook, bossing Never.
Posts: 11,601
Karma: 87456643
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
I agree. It's desirable on paper (registration) so that text on either side of the same sheet/leaf lines up, which will result in body text on adjacent pages aligning. I never heard of it as a requirement for ebooks, which as I said earlier, don't normally have adjacent pages and rarely have two columns, because neither of those work well for most people. Also it only matters on a PDF when you print it duplex.
|
07-23-2023, 01:44 PM | #5 | |||
Wizard
Posts: 2,297
Karma: 12126329
Join Date: Jul 2012
Device: Kobo Forma, Nook
|
Quote:
If you look that up in your favorite search engines, plus append CSS to it, you can find lots of examples:
Within an EPUB? You don't. A lot of this relies on:
Quote:
Quote:
But, the second users begin changing their fonts/settings, all your manual calculations will be thrown off. On the Print (and websites), where YOU control most of the stuff... most users just take what you force down their throats. In ebooks though, USERS control most of these settings, and the settings vary wildly. Also, like other MR users have explained, most ebooks are read on a single-screen device, NOT two-page spreads like physical books. So to enforce a lot of this grid-based layout in EPUB... I just don't see it making a lot of sense. - - - Side Note: If you want to see some of this CSS3 Page-Based Media stuff, see the talk from: I referenced it a few times on MobileRead:
describing some of the nuances of how you turn HTML/EPUB from an "infinite scroll" type thing into "pages". Since then, the W3C absorbed a lot of that info into the: but it's still a work-in-progress. Last edited by Tex2002ans; 07-23-2023 at 02:42 PM. |
|||
Advert | |
|
07-23-2023, 04:04 PM | #6 | ||
Oracle Pig Keeper
Posts: 26
Karma: 5024
Join Date: Jun 2023
Device: Kindle Fire HD, Samsung Tab
|
Quote:
Quote:
I'm just trying to follow their guidelines, since failing to do so may be grounds for a book submission to be rejected. Personally speaking, I think the requirement is an error. It may be possible with a fixed layout book making use of their javascript libraries, but it's not really practical to implement for a flowing book. Last edited by Interrobang; 07-23-2023 at 04:22 PM. |
||
07-23-2023, 05:23 PM | #7 | |
Grand Sorcerer
Posts: 6,554
Karma: 84810789
Join Date: Nov 2011
Location: Tampa Bay, Florida
Device: Kindles
|
Quote:
You mention Kobo and ADE. Some Kindle apps and devices can also show side-by-side pages when in portrait orientation. I have read the Kindle Publishing Guidelines and there is nothing like this Apple page alignment requirement there. Perhaps someone more familiar with Kobo can comment about that platform's requirements. The requirement itself is also odd and subject to different interpretations. If might be seen as applying only if the publisher wishes to to keep text aligned across the spine. Or only if a line-height is specified in the document. It uses "should" instead of "must" which usually indicates something is suggested but not required. Finally doing what it says won't even work in many cases. For example the presence of images on the page will throw the placement of text that follows out of alignment unless images are also sized in multiples of the line height. I find it hard to believe that books from commercial publishers are modified to follow this rule, but I could be wrong. It might be a good idea to ask for clarification in a forum specific to publishing for Apple. Last edited by jhowell; 07-23-2023 at 06:03 PM. |
|
07-23-2023, 05:28 PM | #8 |
the rook, bossing Never.
Posts: 11,601
Karma: 87456643
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
I've never had a book rejected for that. The only thing in about 7 years that Apple objected to was a line reading, "free updates with proof of purchase". But actually if people buy on Smashwords they can freely get any revision since their purchase.
Even the Kobo Elipsa doesn't do two up pages for an ebook (10.3″), nor Sage, Elipsa2, Elipsa, Nia, Touch C, or Aura HD H2O original. Nor does the Elipsa do it with PDFs. I've only ever seen it on PDFs (scans or not) that are actually formatted two pages side by side, or columns. Though I'm sure the Fixed layout epub can do it. I have seen two columns (not pages) done in epub, azw3 and mobi using tables or CSS. It's often dreadful. I edited one ebook that had a short letter in one column and the recipient thinking about it and narration in the second column to be sequential. That was mimicking what was originally on a single page on print edition. J Rowling also had a badly done multicolumn ebook, but again it wasn't two page layout. Anyway, the guidelines are maybe written by someone that's not used regular ebooks and less than a 10" screen. Maybe even a viewer on a desktop. The only way I can sensibly even see two pages PDF is on a 22" QHD or ideally 4k/UHD approximately 23" screen. I'd like a 4K 19" or 20" but can't find one. |
07-23-2023, 05:34 PM | #9 |
Resident Curmudgeon
Posts: 74,582
Karma: 130140792
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
There is no way I could read such a book on my iPhone or Libra 2 (7" screen).
Last edited by JSWolf; 07-23-2023 at 05:36 PM. |
07-23-2023, 05:34 PM | #10 |
the rook, bossing Never.
Posts: 11,601
Karma: 87456643
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
There are apps that will do two pages up in Landscape, but you need a 10″ or bigger screen.
Only printed on paper books have a spine! Only paper needs body text registration. |
07-23-2023, 05:35 PM | #11 |
the rook, bossing Never.
Posts: 11,601
Karma: 87456643
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
|
|
07-23-2023, 06:18 PM | #12 |
Addict
Posts: 233
Karma: 3232318
Join Date: Sep 2009
Device: Sony PRS-300, PRS-T1, PRS-T3
|
Even without a side-by-side display, I can see an aesthetic benefit in a strict alignment where, (regardless of chapter, search headers and dividers), the displayed lines of text remain in the same vertical positions as you turn each page instead of moving slightly up and down the screen. I wouldn't think to require it, but it would be certainly nice to be able to consistently apply within a book.
|
07-23-2023, 06:49 PM | #13 |
Grand Sorcerer
Posts: 6,554
Karma: 84810789
Join Date: Nov 2011
Location: Tampa Bay, Florida
Device: Kindles
|
I took a look at a sample of a popular book in the Books app on my iPad and alignment across the spine for a two page spread was not maintained.
|
07-23-2023, 10:04 PM | #14 | |
Oracle Pig Keeper
Posts: 26
Karma: 5024
Join Date: Jun 2023
Device: Kindle Fire HD, Samsung Tab
|
Quote:
Thanks again everyone for your input. |
|
07-24-2023, 12:59 AM | #15 | |
Wizard
Posts: 2,297
Karma: 12126329
Join Date: Jul 2012
Device: Kobo Forma, Nook
|
Quote:
Similar junk exists in the Amazon publishing guidelines as well. (Like one of the lies saying they "support MathML" or they tell you things that aren't possible in KDP.) You'd "align to the grid"—which may not divide evenly into that screen's text area—then you toss in a few Widows/Orphans, and people would be complaining about these "enormous gaps" at the bottom of their screens. Better to just focus on very clean HTML/CSS + follow best practices as close as you can. Last edited by Tex2002ans; 07-24-2023 at 01:37 AM. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Two-pages image (facing pages) / How to? | 42piratas | ePub | 24 | 11-10-2022 02:01 PM |
optional (double pages, facing pages) | kelly33 | Kindle Formats | 0 | 11-08-2012 01:02 AM |
Right Aligning Wrapped Text Only | ghostyjack | ePub | 7 | 11-04-2010 08:54 AM |
Correctly Aligning Text Within a Table | ghostyjack | ePub | 3 | 07-28-2010 07:18 AM |
Turning Scanned PDFs with facing pages into single pages | jimteacher | Workshop | 5 | 11-09-2009 02:59 PM |