font-matching-rule-013

Font Matching Algorithm, font-variant font missing small-caps property

WeasyPrint

This browser

Flags
font
Assertion
A font that is only available as small-caps can be assigned either a normal or a small-caps to its font-variant property. Both values have the same effect.

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: Font Matching Algorithm, font-variant font missing small-caps property</title>
 5         <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
 6         <link rel="help" href="http://www.w3.org/TR/CSS21/fonts.html#algorithm">
 7         <meta name="flags" content="font">
 8         <meta name="assert" content="A font that is only available as small-caps can be assigned either a normal or a small-caps to its font-variant property. Both values have the same effect.">
 9         <style type="text/css">
10             span
11             {
12                 font-family: SmallCaps;
13             }
14             #span1
15             {
16                 font-variant: normal;
17             }
18             #span2
19             {
20                 font-variant: small-caps;
21             }
22         </style>
23     </head>
24     <body>
25         <p>PREREQUISITE: Operating system needs to have the '<a href="support/AHEM_smallcaps.ttf">Small Caps</a>' font installed.</p>
26         <p>Post Test: Remove test font after running the test.</p>
27         <p>Test passes if there is a box below and the top edge is not jagged.</p>
28         <div>
29             <span id="span1">X</span><span id="span2">X</span>
30         </div>
31     </body>
32 </html>