- From: Alex Mogilevsky <alexmog@exchange.microsoft.com>
- Date: Wed, 22 Aug 2007 23:44:00 -0700
- To: fantasai <fantasai.lists@inkedblade.net>, "Grant, Melinda" <melinda.grant@hp.com>
- CC: "www-style@w3.org" <www-style@w3.org>
Fantasai wrote: > >> Using named pages > >> > >> What happens in the following example > >> <div> > >> <p>...</p> > >> </div> > >> <div> > >> <p>...</p> > >> </div> > > I don't think it's clear what happens in this case if I put borders on > all four elements. Where are the page breaks and how do you know? If > the > content-empty page suppression is what's keeping me from getting blank > pages, do the divs' top borders not get rendered because they are on > empty > pages? I agree with Melinda's answer that the divs don't generated empty pages. If they did it wouldn't be welcomed by pretty much anyone. It will also make the best user experience if borders close around actual content. That would mean the behavior is somewhat similar to margin collapsing - no new pages until non-empty content is present... I really wouldn't want to create something as complicated as margin collapsing, but so far it seems doable, at least not more complicated. So, would it be reasonable to say "rules that modify page properties come in effect when non-empty content is encountered"? Then clearly any number of nested blocks with specified page breaks or named pages accumulate changes until some non-empty content is found. And there is never a lost top border... > >> Forced page breaks > >> ------------------ > >> > >> It does not appear to be defined whether in > >> <div></div> > >> <p></p> > >> with > div { page-break-after: left; } > p { page-break-before: always; } > or > div { page-break-after: left; } > p { page-break-before: right; } > >> the P's contents are required to appear on a left page, right > >> page, or any page. By the same logic, none of the above - the paragraph doesn't have any content, so it depends on what comes after. Assuming the next non-empty block doesn't have any page rules, its page side is the accumulated set of properties from previous elements (left in the first case, right in second). Does that sound reasonable? --alex
Received on Thursday, 23 August 2007 06:44:20 UTC