Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 09-27-2014, 01:54 PM   #1
mmat1
Berti
mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.mmat1 ought to be getting tired of karma fortunes by now.
 
mmat1's Avatar
 
Posts: 1,190
Karma: 4623570
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
EPub to PDF, Orphans and Pagebreaks

I want to convert some of my E-Pubs to PDF.

1) How do I avoid orphans and widows? Callibre seams to ignore these attributes in any place if the CSS.

2) How do I keep Stuff together ?
Things like:
<h3>Headline</h3>
<p class "subtitle">supptitle</p>
<p>first paragraph of Text</p>

should not be ripped apart. Callibre seams to ignore the "page-break-after: avoid"

Last edited by mmat1; 09-27-2014 at 01:56 PM.
mmat1 is offline   Reply With Quote
Old 09-27-2014, 11:52 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 37,331
Karma: 16448187
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
calibre uses webkit's css3 columns implementation to paginate ebooks for conversion to PDF. As far as I know, columns does not support widows and orphans. page-break-after:void should be supported, but note that it is simply a request, if the text does nto fit on the page, it will be broken.
kovidgoyal is offline   Reply With Quote
Advert
Old 03-26-2015, 05:39 PM   #3
bowlins
Member
bowlins began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Jul 2014
Device: none
I've just been experimenting with widows and orphans and may have found a temporary workaround.

The solution is a bit precarious and I wouldn't trust it 100%. At first, the rules seemed to work. However, since webkit doesn't seem to support orphans/widows for screen media, I tested with more books and, indeed, the properties were buggy. They were breaking the text but the following trick seems to work for now:

Code:
div {
   page-break-after:avoid;
   page-break-before:avoid;
   page-break-inside:avoid;
}
p {
   page-break-after:avoid;
   widows: 2;
   orphans: 2;
}
On its own, widows and orphans seem to work on plain text. However, divs and images may change the flow and create broken text, paragraph duplication and other nasty bugs.

In my case, adding the page break rules for divs too seems to do the trick (for now)
bowlins is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PDF pagebreaks turn to blank lines in mobi daniel3ub Conversion 14 08-28-2012 10:31 PM
Problems with pagebreaks in MOBI ebookn00b Kindle Formats 1 04-20-2012 11:12 AM
How to insert pagebreaks using MS Office on HTMLZ? gertblij Conversion 4 10-18-2011 05:47 AM
Unwanted Pagebreaks Timoleon Calibre 3 09-19-2010 07:53 PM
Epub and pagebreaks mtravellerh Calibre 3 11-02-2008 05:30 PM


All times are GMT -4. The time now is 02:17 PM.


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