Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old Today, 02:21 PM   #1
Siavahda
Addict
Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.
 
Posts: 268
Karma: 9400
Join Date: Aug 2010
Location: Helsinki
Device: Kobo Clara Colour
What can invisibly cause a pagebreak?

I have an epub file and can't figure out what's causing a pagebreak.

Code:
<p class="noindent2">In the dungeons, the Queen sat in near perfect darkness. She had one window, high in the wall of her cell, and it allowed in some light during the day. She had a bed, and wall hangings and clean linen, and excellent food.</p>
<p class="indent">And very careful guards. She didn’t know any of them, despite their red surcoats. But they were cautious and courteous.</p>
On my Kobo, after that noindent2 paragraph there's a pagebreak. But there's no reason for it in the css. noindent2 is used in a thousand other places just fine without creating a pagebreak, and the indent class after it is used for most paragraphs in the book, it doesn't cause a pagebreak anywhere else either.

Code:
.noindent2 {
  display: block;
  font-size: 1em;
  line-height: 1;
  text-align: justify;
  text-indent: 0;
  margin: 1em 0 0 0;
}
.indent {
  display: block;
  font-size: 1em;
  line-height: 1;
  text-align: justify;
  text-indent: 1em;
  margin: 0;
}
I created a noindent3 just for that paragraph, but that made no difference to the pagebreak. I can do anything else as usual - change the margins for the paragraph, etc - but the pagebreak appears whatever I do. I tried page-break-after: avoid, and tried adding page-break-before: avoid to the basic indent rule. Made no difference.

Aside from the ones I added, there's no page-break rule anywhere in the stylesheet.

In the Calibre Editor and in Sigil, there is no other code around that paragraph. In the Calibre Viewer/Sigil preview, there's no pagebreak visible. But in Adobe Digital Editions, and on my Kobo, there's a pagebreak there.

I have widows and orphans removed from the stylesheet, so it's not that.

So - what can cause a pagebreak in an epub file, without a page-break-after rule or visible bit of code around a given paragraph? What should I be looking for?

This is all with EPUB, not KEPUB, if that's relevant.

Also, I'm not great with terminology etc, so please explain any theories like I'm 5!
Siavahda is offline   Reply With Quote
Old Today, 02:29 PM   #2
Siavahda
Addict
Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.Siavahda can eat soup with a fork.
 
Posts: 268
Karma: 9400
Join Date: Aug 2010
Location: Helsinki
Device: Kobo Clara Colour
Also, because it has sometimes helped with issues like this in the past, I converted the file to AZW3, but the Calibre Editor still didn't show me any code that would explain the pagebreak.
Siavahda is offline   Reply With Quote
Advert
Old Today, 02:44 PM   #3
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,499
Karma: 21099999
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
One possibility - you might try looking at the widows/orphans setting. Under ePub 2 you can set that and it can have the effect of pushing sentences to the next page - which looks a lot like a page break.
If you are using ePub 3 that wouldn’t be in the css, but it may be a default in your Kobo??? Others here are more knowledgeable about koboisms.

Cheers,
Turtle91 is offline   Reply With Quote
Old Today, 04:24 PM   #4
Karellen
Wizard
Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.
 
Karellen's Avatar
 
Posts: 1,900
Karma: 9600930
Join Date: Sep 2021
Location: Australia
Device: Kobo Libra 2
Following on from the comment by Tuttle91, if you change the font size on your kobo, does the page break still occur at the same place or does it move with the changing font size?

If it stays at the same place, we'd need to see the ebook in total.
Karellen is online now   Reply With Quote
Reply

Tags
epub, pagebreak


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
unwanted pagebreak travger Conversion 3 05-04-2014 05:40 AM
h1 pagebreak without h2 bookdragon Sigil 5 03-03-2014 06:11 AM
HELP from Pagebreak !! Smashword Tara198 Writers' Corner 4 07-06-2013 06:22 PM
0.6.3 pagebreak before h2 only every second time? flowoeB Calibre 4 07-31-2009 01:47 AM
XPath Help and Pagebreak emellaich Calibre 3 07-28-2009 02:17 PM


All times are GMT -4. The time now is 04:31 PM.


MobileRead.com is a privately owned, operated and funded community.