text-align-008

text-align - match-parent (basic)

WeasyPrint

Reference (good) by WeasyPrint

Reference (good) by this browser

This browser

Assertion
The 'text-align' property set to 'match-parent' on a block element behaves the same as 'inherit'.

Source

 1 <!DOCTYPE html>
 2 <html><head><meta charset="utf-8">
 3 <title>CSS Text Test: text-align - match-parent (basic)</title>
 4 <link href="http://www.intel.com" rel="author" title="Intel">
 5 <link href="mailto:shiyoux.tan@intel.com" rel="author" title="Shiyou Tan">
 6 <link href="http://www.w3.org/TR/css-text-3/#text-align" rel="help" title="7.1. Text Alignment: the 'text-align' property">
 7 <link href="reference/text-align-007-ref.htm" rel="match">
 8 <meta content="" name="flags">
 9 <meta content="The 'text-align' property set to 'match-parent' on a block element behaves the same as 'inherit'." name="assert">
10 <style>
11   body {
12     text-align: end;
13   }
14 
15   p {
16     text-align: left;
17   }
18 
19   div {
20     border: 1px solid blue;
21     text-align: match-parent;
22   }
23 </style>
24 </head><body>
25   <p>Test passes if the words "Filler Text" below are aligned to the right, inside the blue box.</p>
26   <div>Filler Text</div>
27 
28 </body></html>