1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/reftests/font-face/name-collision-bad-url.html Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,154 @@ 1.4 +<!DOCTYPE HTML> 1.5 +<html> 1.6 +<head> 1.7 +<title>Font name collision test</title> 1.8 +<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 1.9 + 1.10 +<!-- 1.11 + Font family names in @font-face rules take precedence over locally-available font families, 1.12 + so none of the names of commonly used platform fonts should match against locally available 1.13 + fonts. 1.14 +--> 1.15 + 1.16 +<style type="text/css"> 1.17 + 1.18 +@font-face { 1.19 + font-family: fallback; 1.20 + src: url(../fonts/mplus/mplus-1p-regular.ttf); 1.21 +} 1.22 + 1.23 +body { 1.24 + margin: 50px; 1.25 + font-family: fallback; 1.26 +} 1.27 + 1.28 +table { 1.29 + margin-left: 3em; 1.30 +} 1.31 + 1.32 +@font-face { 1.33 + font-family: Sample; 1.34 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.35 + font-weight: 900; 1.36 +} 1.37 + 1.38 +.sample { font-family: Sample, fallback; } 1.39 + 1.40 +/* Windows */ 1.41 + 1.42 +@font-face { 1.43 + font-family: Arial; 1.44 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.45 + font-weight: 900; 1.46 +} 1.47 + 1.48 +.arial { font-family: Arial, fallback; } 1.49 + 1.50 +@font-face { 1.51 + font-family: Times New Roman; 1.52 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.53 + font-weight: 900; 1.54 +} 1.55 + 1.56 +.timesnewroman { font-family: Times New Roman, fallback; } 1.57 + 1.58 +@font-face { 1.59 + font-family: Courier New; 1.60 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.61 + font-weight: 900; 1.62 +} 1.63 + 1.64 +.couriernew { font-family: Courier New, fallback; } 1.65 + 1.66 +/* Mac OS X */ 1.67 + 1.68 +@font-face { 1.69 + font-family: Futura; 1.70 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.71 + font-weight: 900; 1.72 +} 1.73 + 1.74 +.futura { font-family: Futura, fallback; } 1.75 + 1.76 +@font-face { 1.77 + font-family: Helvetica; 1.78 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.79 + font-weight: 900; 1.80 +} 1.81 + 1.82 +.helvetica { font-family: Helvetica, fallback; } 1.83 + 1.84 +@font-face { 1.85 + font-family: Times; 1.86 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.87 + font-weight: 900; 1.88 +} 1.89 + 1.90 +.times { font-family: Times, fallback; } 1.91 + 1.92 +@font-face { 1.93 + font-family: Courier; 1.94 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.95 + font-weight: 900; 1.96 +} 1.97 + 1.98 +.courier { font-family: Courier, fallback; } 1.99 + 1.100 +/* Linux */ 1.101 + 1.102 +@font-face { 1.103 + font-family: Bitstream Vera Sans; 1.104 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.105 + font-weight: 900; 1.106 +} 1.107 + 1.108 +.bitstreamverasans { font-family: Bitstream Vera Sans, fallback; } 1.109 + 1.110 +@font-face { 1.111 + font-family: DejaVu Sans; 1.112 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.113 + font-weight: 900; 1.114 +} 1.115 + 1.116 +.dejavusans { font-family: DejaVu Sans, fallback; } 1.117 + 1.118 +@font-face { 1.119 + font-family: FreeSans; 1.120 + src: url(../fonts/bogus-dir/bogus-font.ttf); 1.121 + font-weight: 900; 1.122 +} 1.123 + 1.124 +.freesans { font-family: FreeSans, fallback; } 1.125 + 1.126 +table { 1.127 + font-family: Sample; 1.128 +} 1.129 + 1.130 +table td { 1.131 + font-size: 24pt; 1.132 +} 1.133 + 1.134 +</style> 1.135 + 1.136 +</head> 1.137 + 1.138 +<body> 1.139 + 1.140 +<p>All text below should appear in the same "fallback" font face:</p> 1.141 + 1.142 +<table> 1.143 +<tr class="sample"><td>Sample</td></tr> 1.144 +<tr class="arial"><td>Arial</td></tr> 1.145 +<tr class="timesnewroman"><td>Times New Roman</td></tr> 1.146 +<tr class="couriernew"><td>Courier New</td></tr> 1.147 +<tr class="futura"><td>Futura</td></tr> 1.148 +<tr class="helvetica"><td>Helvetica</td></tr> 1.149 +<tr class="times"><td>Times</td></tr> 1.150 +<tr class="courier"><td>Courier</td></tr> 1.151 +<tr class="bitstreamverasans"><td>Bitstream Vera Sans</td></tr> 1.152 +<tr class="dejavusans"><td>DejaVu Sans</td></tr> 1.153 +<tr class="freesans"><td>FreeSans</td></tr> 1.154 +</table> 1.155 + 1.156 +</body> 1.157 +</html>