escapes-016.xht (2997B)
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 2 3 <html xmlns="http://www.w3.org/1999/xhtml"> 4 5 <head> 6 7 <title>CSS Test: Escape of non-printable characters within declarations, applying to property values</title> 8 9 <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> 10 <link rel="help" href="http://www.w3.org/TR/CSS21/syndata.html#rule-sets" title="4.1.7 Rule sets, declaration blocks, and selectors" /> 11 <link rel="match" href="../reference/ref-if-there-is-no-red.xht" /> 12 13 <meta content="invalid" name="flags" /> 14 <meta content="red is a reserved (color name) keyword while red\9 is not a reserved keyword. red\9 is made of red with an escaped horizontal tab. That is why the parsing of the declaration should fail. Same thing with the other 23 tests (see test escapes-015)." name="assert" /> 15 16 <!-- 17 This test is a much more elaborated version of the test 18 http://test.csswg.org/suites/css2.1/nightly-unstable/html4/escapes-002.htm 19 and 20 http://test.csswg.org/suites/css2.1/nightly-unstable/html4/escapes-014.htm 21 --> 22 23 <style type="text/css"><![CDATA[ 24 div 25 { 26 color: white; 27 font-size: 1.25em; 28 line-height: 1.2; 29 } 30 31 /* 32 U+0009 is an horizontal tab 33 U+000A is a line feed 34 U+000B is a vertical tab 35 U+000C is a form feed 36 U+000D is a carriage return 37 U+0020 is a blank white space 38 */ 39 40 div#thirteenth 41 { 42 color: \9 red; 43 } 44 45 div#fourteenth 46 { 47 color: \9red; 48 } 49 50 div#fifteenth 51 { 52 color: \A red; 53 } 54 55 div#sixteenth 56 { 57 color: \Ared; 58 } 59 60 div#seventeenth 61 { 62 color: \B red; 63 } 64 65 div#eighteenth 66 { 67 color: \Bred; 68 } 69 70 /* 71 U+0009 is an horizontal tab 72 U+000A is a line feed 73 U+000B is a vertical tab 74 U+000C is a form feed 75 U+000D is a carriage return 76 U+0020 is a blank white space 77 */ 78 79 div#nineteenth 80 { 81 color: \C red; 82 } 83 84 div#twentieth 85 { 86 color: \Cred; 87 } 88 89 div#twenty-first 90 { 91 color: \D red; 92 } 93 94 div#twenty-second 95 { 96 color: \Dred; 97 } 98 99 div#twenty-third 100 { 101 color: \20 red; 102 } 103 104 div#twenty-fourth 105 { 106 color: \20red; 107 } 108 109 /* 110 U+0009 is an horizontal tab 111 U+000A is a line feed 112 U+000B is a vertical tab 113 U+000C is a form feed 114 U+000D is a carriage return 115 U+0020 is a blank white space 116 */ 117 118 ]]></style> 119 120 </head> 121 122 <body> 123 124 <p>Test passes if there is <strong>no red</strong>.</p> 125 126 <div id="thirteenth">13th test FAILED</div> 127 128 <div id="fourteenth">14th test FAILED</div> 129 130 <div id="fifteenth">15th test FAILED</div> 131 132 <div id="sixteenth">16th test FAILED</div> 133 134 <div id="seventeenth">17th test FAILED</div> 135 136 <div id="eighteenth">18th test FAILED</div> 137 138 <div id="nineteenth">19th test FAILED</div> 139 140 <div id="twentieth">20th test FAILED</div> 141 142 <div id="twenty-first">21st test FAILED</div> 143 144 <div id="twenty-second">22nd test FAILED</div> 145 146 <div id="twenty-third">23rd test FAILED</div> 147 148 <div id="twenty-fourth">24th test FAILED</div> 149 150 </body> 151 </html>