Originally Posted by Jellby
I'm not sure what you mean... immediately after a page break, all vertical space should be collapsed and discarded, but only the space before the next element's content (which can be an empty div). So, if you have a pagebreak and then an h1 with top margin, the margin will be ignored; if you have a pagebreak and a div with an h1 inside, both top margins or the div and h1 will be discarded (I believe), but if the h1 is outside and after the div, then the bottom margin of the div and the top margin of the h1 will be displayed.
Ah, I understand. Well, I was talking about an h#
contained in a div
. There is nothing in my files that wouldn't
be contained in a div
. It's nothing but div
s containing content (cover, chapters, etc.) I'm trying to use div
s for only highest-level containers.
Still, now that I understand, I don't foresee a problem for my books. It actually makes sense to me that the vertical margin would collapse -- it seems desirable to do that. Padding is enough, I think.
don't like it, and I think if I were using image backgrounds for my headers I wouldn't like it either... Hmmm. Is it occurring on your reader, in your browser, where? Can you point to a spec that defines it? Crazy question: can you add bottom margin to the pseudo-class? (BTW, why don't you
I don't like the empty divs either, but I only use them in my ePUBs when I want a manual page break inside a file, which is not often (usually page breaks are between two files/chapters, which is fine).
I'm still thinking about using hr
s. I know that they are not strictly structure, but two things: a) they mark the page break when you aren't using a paged reader (like a browser) and b) is it really any different than an image? It's sorta like content, isn't it? "Here is a visual indicator of the end of the page!"
I guess there's a c), too: it doesn't have to display, with CSS.
[Also, d) I come from the old RocketBook world, where <hr size=0>
and <hr new-page>
were page markers. So it feels
reasonable. "Feels reasonable", kinda an oxymoron...]
And if I can do it for page-breaks, it seems right for scene-breaks too!
m a r