%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
<!DOCTYPE html> <html> <head> <meta charset=big5> <!-- test breaks if the server overrides this --> <title>Big5 encoding ASCII</title> <meta name="timeout" content="long"> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> <link rel='author' title='Richard Ishida' href='mailto:ishida@w3.org'> <link rel='help' href='https://encoding.spec.whatwg.org/#big5'> <meta name="assert" content="The browser produces the characters when encoding ASCII in a Big5-encoded document."> </head> <body> <div id=log></div> <script> // index is Big5 index pointer, value is Unicode codepoint (dec) function encode(input, output, desc) { // tests whether a Unicode character is converted to an equivalent Big5 %-encoded byte sequence by href // input: a escaped Unicode code point from the list of characters in the Big5 index // output: expected percent-encoded byte sequence for the code point's equivalent in Big5 encoding // desc: what's being tested test(function() { var a = document.createElement("a"); // <a> uses document encoding for URL's query // Append and prepend x to test for off-by-one errors a.href = "https://example.com/?x" + input + "x"; assert_true( a.search.substr(1) == "x" + output + "x" || a.search.substr(1) == "x" + input + "x" ); // remove leading "?" }, "big5 encoder: " + desc); } // test ASCII - test separately for chars that aren't escaped for (var a = 0; a < 0x7f; a++) { // The first 3 are stripped from URLs and the last is # which introduces a new URL segment if (a === 0x09 || a === 0x0a || a === 0x0d || a === 0x23) { continue; } hex = a.toString(16).toUpperCase(); while (hex.length < 2) { hex = "0" + hex; } encode( String.fromCharCode(a), "%" + hex, "test for ASCII codepoint 0x" + a.toString(16) + " " + String.fromCharCode(a) ); } </script> </body> </html>