vertical-align-104

Vertical-align using percentages with a positive nominal value, +100%

WeasyPrint

This browser

Flags
ahem
Assertion
The 'vertical-align' property sets a positive nominal length value in percentages.

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: Vertical-align using percentages with a positive nominal value, +100%</title>
 5         <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
 6         <link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#propdef-vertical-align">
 7         <link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#leading">
 8         <meta name="flags" content="ahem">
 9         <meta name="assert" content="The 'vertical-align' property sets a positive nominal length value in percentages.">
10         <style type="text/css">
11             div
12             {
13                 font: 20px/1 Ahem;
14                 height: 1em;
15                 line-height: 1em;
16                 position: relative;
17                 width: 1em;
18             }
19             #div2
20             {
21                 color: red;
22             }
23             #div3
24             {
25                 position: absolute;
26                 top: 0;
27             }
28             #div4
29             {
30                 position: absolute;
31                 top: 100%;
32                 left: 1em;
33             }
34             #span1
35             {
36                 vertical-align: +100%;
37             }
38         </style>
39     </head>
40     <body>
41         <p>Test passes if there is at least one black box and there is no red visible on the page.</p>
42         <div id="div1">
43             <div id="div2">
44                 <span id="span1">X</span>X
45             </div>
46             <div id="div3">X</div>
47             <div id="div4">X</div>
48         </div>
49     </body>
50 </html>