padding-applies-to-017

CSS Tables: Bottom Padding on Inline Children

WeasyPrint

This browser

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: CSS Tables: Bottom Padding on Inline Children</title>
 5   <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch">
 6   <link rel="reviewer" title="Elika J. Etemad" href="http://fantasai.inkedblade.net/contact">
 7   <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/table/012.xml" type="application/xhtml+xml">
 8   <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#padding-properties">
 9   <style type="text/css">
10    /* reset everything to be sure we don't introduce oddities */
11    table { border: 0; border-spacing: 0; padding: 0; margin: 0; line-height: 1; }
12    td { border: 0; padding: 0; margin: 0; line-height: 1; }
13    span { border: 0; padding: 0; margin: 0; line-height: 1; display: inline; }
14 
15    /* the test */
16    table { background: red; }
17    span.control { background: green; color: white; }
18    span.test { padding-bottom: 10em; }
19   </style>
20  </head>
21  <body>
22   <table>
23    <tr>
24     <td>
25      <span class="test"><span class="control">There should be no red on this page.</span></span>
26     </td>
27    </tr>
28   </table>
29  </body>
30 </html>