Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 02-16-2014, 11:21 AM   #1
bookdragon
Junior Member
bookdragon began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jan 2012
Device: Kindle
h1 pagebreak without h2

I am formatting a book of poetry and have used this in the css to create a page break between each poem.

h1 {
page-break-before: always;
}

My problem is it is breaking at h2 as well. Since some poems are broken into multiple parts with each part marked h2 this is not good.

Does anyone know how I can fix this??

Thanks!
bookdragon is offline   Reply With Quote
Old 02-16-2014, 11:45 AM   #2
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,358
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Does anyone know how I can fix this??
By taking out the css that tells it break at h2?
That's not default behavior in the epub readers I have experience with... so I assume something in the css is telling it to do so. What are you viewing the epub with?

Please tell me it's not a Kindle after you've converted the epub to a kindlebook with calibre. If so, it's very likely a calibre conversion setting that's tripping you up, and not the css/xhtml of the epub at all.
DiapDealer is offline   Reply With Quote
Advert
Old 02-16-2014, 12:46 PM   #3
bookdragon
Junior Member
bookdragon began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jan 2012
Device: Kindle
I am using the Calibre ebook viewer as I edit to see the effects of my changes. The book however is intended to be uploaded to Amazon so their conversions will occur in the final product.

I do not have anything in the css about breaking at h2. My css is as below. The book seems to be breaking at each TOC entry now, yet it did not break at all prior to my adding the h1 break. I ended up creating a copy then removing the H2 tags and using a bold font at the heading of each part and redoing my TOC to Just H1 heading so the poems can stay intact. This worked as expected. I am however editing several books of poetry and would like to figure out how to get this to work correctly in my next project.

Spoiler:

@page {
margin-bottom: 5pt;
margin-top: 5pt;
}

h1 {
page-break-before: always;
}


.calibre {
display: block;
font-size: 1em;
line-height: 1.2;
padding-left: 0;
padding-right: 0;
text-align: justify;
margin: 0 5pt
}
.calibre1 {
display: block;
margin: 1em 0
}
.calibre2 {
height: auto;
width: auto
}
.calibre3 {
display: block;
font-size: 1.5em;
font-weight: bold;
line-height: 1.2;
text-indent: 0;
margin: 0
}
.calibre4 {
font-size: 0.66667em;
line-height: 1.2
}
.calibre5 {
display: block
}
.calibre6 {
display: block;
text-indent: 0;
margin: 0
}
.calibre7 {
font-size: 0.75em;
line-height: 1.2;
vertical-align: sub
}
.calibre8 {
display: block;
font-size: 0.75em;
height: 1em;
line-height: 1.2;
border: currentColor none 0;
margin: 0
}
.calibre9 {
font-size: 0.75em
}
.calibre10 {
display: block;
font-size: 1.375em;
font-weight: bold;
line-height: 1.2;
text-indent: 0;
margin: 0
}
.calibre11 {
font-size: 0.54545em;
line-height: 1.2
}
.calibre12 {
display: block
}
.calibre13 {
display: block;
padding-left: 20px
}
.calibre14 {
display: block;
font-size: 1em;
line-height: 1.2;
padding-left: 0;
padding-right: 0;
margin: 0 5pt
}
.calibre15 {
display: block;
padding-left: 10px
}
.italic {
font-style: italic
}

Last edited by theducks; 02-16-2014 at 02:05 PM. Reason: Wrapped long paste in Spoiler
bookdragon is offline   Reply With Quote
Old 02-17-2014, 04:06 AM   #4
cybmole
Wizard
cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.cybmole ought to be getting tired of karma fortunes by now.
 
Posts: 3,720
Karma: 1759970
Join Date: Sep 2010
Device: none
how many xhtml files do you have - a reader will break on every new file irrespective of H tags
cybmole is offline   Reply With Quote
Old 03-02-2014, 07:47 PM   #5
exaltedwombat
Guru
exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.exaltedwombat ought to be getting tired of karma fortunes by now.
 
Posts: 878
Karma: 2457540
Join Date: Nov 2011
Device: none
Yes, if you want a page-break, why not put in a page-break? Which in Sigil means splitting the html file. It's easy to do.
exaltedwombat is offline   Reply With Quote
Advert
Old 03-03-2014, 06:11 AM   #6
mrmikel
Color me gone
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
These particular issues aside, formatting poetry is something much discussed on this forum. It is difficult to get it right at one text size, let alone when the user punches the increase size button.

If it must be a certain layout then epub may not be for you, since it is by its very nature designed to reflow. This is not say don't try, but don't bet the farm on it. If the user increases the size large enough, it will break somewhere where you may not want it to.
mrmikel is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
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
BD: Auto pagebreak preceding chapter? Xsavior Sony Reader 5 07-15-2007 04:21 PM


All times are GMT -4. The time now is 11:27 PM.


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