page-container-009

Paged Media Body Background

WeasyPrint

This browser

Flags
paged
Assertion
For documents in the html namespace, a background on 'body' will cover the page area.

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: Paged Media Body Background</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/visudet.html#containing-block-details">
 7   <link rel="help" href="http://www.w3.org/TR/css3-page/#painting">
 8   <meta name="flags" content="paged">
 9   <meta name="assert" content="For documents in the html namespace, a background on 'body' will cover the page area.">
10   <style type="text/css">
11     @page {
12         margin: 7%;
13     }
14     html {
15         background-color: inherit;
16         background-image: inherit;
17 }
18     body {
19         background-color: #ddffdd;
20 }
21 
22   </style>
23  </head>
24  <body>
25    <div>
26      <p>There is a white margin around the edge of this page.  The top and
27      bottom margins are of equal height, and the right and left margins are of
28      equal width. The rest of the page,
29      including this text, has a pale green background.
30      </p>
31    </div>
32  </body>
33 </html>