page-breaks-100

Page breaks: clearing bottom margin

WeasyPrint

This browser

Flags
paged
Assertion
When an element would span a page break solely to satisfy a descendant's bottom margin, that margin is instead truncated and the element does not span pages.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3  <head>
 4   <title>CSS Test: Page breaks: clearing bottom margin</title>
 5   <link rel="author" title="Melinda Grant" href="mailto:melinda.grant@hp.com">
 6   <link rel="help" href="http://www.w3.org/TR/CSS21/page.html#allowed-page-breaks">
 7   <link rel="help" href="http://www.w3.org/TR/css3-page/#allowed-pg-brk">
 8   <meta name="flags" content="paged">
 9   <meta name="assert" content="When an element would span a page break solely to satisfy a descendant's bottom margin, that margin is instead truncated and the element does not span pages.">
10   <style type="text/css">
11   
12     p {
13         margin-bottom: 12in;
14     }
15  
16   </style>
17  </head>
18  <body>
19    <div>
20      <p>This test produces only one page on paged media, containing only this paragraph.</p>
21    </div>
22  </body>
23 </html>