OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. |
3 * Copyright (C) 2006 Alexey Proskuryakov <ap@nypop.com> | 3 * Copyright (C) 2006 Alexey Proskuryakov <ap@nypop.com> |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 registrar("ISO8859-8-I", "ISO-8859-8-I"); | 166 registrar("ISO8859-8-I", "ISO-8859-8-I"); |
167 registrar("ISO8859-9", "ISO-8859-9"); | 167 registrar("ISO8859-9", "ISO-8859-9"); |
168 registrar("ISO8859-10", "ISO-8859-10"); | 168 registrar("ISO8859-10", "ISO-8859-10"); |
169 registrar("ISO8859-13", "ISO-8859-13"); | 169 registrar("ISO8859-13", "ISO-8859-13"); |
170 registrar("ISO8859-14", "ISO-8859-14"); | 170 registrar("ISO8859-14", "ISO-8859-14"); |
171 registrar("ISO8859-15", "ISO-8859-15"); | 171 registrar("ISO8859-15", "ISO-8859-15"); |
172 // No need to have an entry for ISO8859-16. ISO-8859-16 has just one label | 172 // No need to have an entry for ISO8859-16. ISO-8859-16 has just one label |
173 // listed in WHATWG Encoding Living Standard (http://encoding.spec.whatwg.or
g/ ). | 173 // listed in WHATWG Encoding Living Standard (http://encoding.spec.whatwg.or
g/ ). |
174 | 174 |
175 // Additional aliases present in the WHATWG Encoding Standard | 175 // Additional aliases present in the WHATWG Encoding Standard |
176 // and Firefox (24), but not in ICU 4.6. | 176 // and Firefox (as of Oct 2014), but not in the upstream ICU. |
| 177 // Three entries for windows-1252 need not be listed here because |
| 178 // TextCodecLatin1 registers them. |
| 179 // FIXME: We may introduce SYSTEM_ICU and enclose this block |
| 180 // with |#if SYSTEM_ICU| because Chromium's ICU has them all. |
177 registrar("csiso58gb231280", "GBK"); | 181 registrar("csiso58gb231280", "GBK"); |
178 registrar("csiso88596e", "ISO-8859-6"); | 182 registrar("csiso88596e", "ISO-8859-6"); |
179 registrar("csiso88596i", "ISO-8859-6"); | 183 registrar("csiso88596i", "ISO-8859-6"); |
180 registrar("csiso88598e", "ISO-8859-8"); | 184 registrar("csiso88598e", "ISO-8859-8"); |
181 registrar("gb_2312", "GBK"); | 185 registrar("gb_2312", "GBK"); |
182 registrar("iso88591", "windows-1252"); | |
183 registrar("iso88592", "ISO-8859-2"); | 186 registrar("iso88592", "ISO-8859-2"); |
184 registrar("iso88593", "ISO-8859-3"); | 187 registrar("iso88593", "ISO-8859-3"); |
185 registrar("iso88594", "ISO-8859-4"); | 188 registrar("iso88594", "ISO-8859-4"); |
186 registrar("iso88595", "ISO-8859-5"); | 189 registrar("iso88595", "ISO-8859-5"); |
187 registrar("iso88596", "ISO-8859-6"); | 190 registrar("iso88596", "ISO-8859-6"); |
188 registrar("iso88597", "ISO-8859-7"); | 191 registrar("iso88597", "ISO-8859-7"); |
189 registrar("iso88598", "ISO-8859-8"); | 192 registrar("iso88598", "ISO-8859-8"); |
190 registrar("iso88599", "windows-1254"); | 193 registrar("iso88599", "windows-1254"); |
191 registrar("iso885910", "ISO-8859-10"); | 194 registrar("iso885910", "ISO-8859-10"); |
192 registrar("iso885911", "windows-874"); | 195 registrar("iso885911", "windows-874"); |
193 registrar("iso885913", "ISO-8859-13"); | 196 registrar("iso885913", "ISO-8859-13"); |
194 registrar("iso885914", "ISO-8859-14"); | 197 registrar("iso885914", "ISO-8859-14"); |
195 registrar("iso885915", "ISO-8859-15"); | 198 registrar("iso885915", "ISO-8859-15"); |
196 registrar("iso_8859-1", "windows-1252"); | |
197 registrar("iso_8859-2", "ISO-8859-2"); | 199 registrar("iso_8859-2", "ISO-8859-2"); |
198 registrar("iso_8859-3", "ISO-8859-3"); | 200 registrar("iso_8859-3", "ISO-8859-3"); |
199 registrar("iso_8859-4", "ISO-8859-4"); | 201 registrar("iso_8859-4", "ISO-8859-4"); |
200 registrar("iso_8859-5", "ISO-8859-5"); | 202 registrar("iso_8859-5", "ISO-8859-5"); |
201 registrar("iso_8859-6", "ISO-8859-6"); | 203 registrar("iso_8859-6", "ISO-8859-6"); |
202 registrar("iso_8859-7", "ISO-8859-7"); | 204 registrar("iso_8859-7", "ISO-8859-7"); |
203 registrar("iso_8859-8", "ISO-8859-8"); | 205 registrar("iso_8859-8", "ISO-8859-8"); |
204 registrar("iso_8859-9", "windows-1254"); | 206 registrar("iso_8859-9", "windows-1254"); |
205 registrar("iso_8859-15", "ISO-8859-15"); | 207 registrar("iso_8859-15", "ISO-8859-15"); |
206 registrar("koi8_r", "KOI8-R"); | 208 registrar("koi8_r", "KOI8-R"); |
207 registrar("x-cp1252", "windows-1252"); | |
208 registrar("x-cp1253", "windows-1253"); | 209 registrar("x-cp1253", "windows-1253"); |
209 registrar("x-cp1254", "windows-1254"); | 210 registrar("x-cp1254", "windows-1254"); |
210 registrar("x-cp1255", "windows-1255"); | 211 registrar("x-cp1255", "windows-1255"); |
211 registrar("x-cp1256", "windows-1256"); | 212 registrar("x-cp1256", "windows-1256"); |
212 registrar("x-cp1257", "windows-1257"); | 213 registrar("x-cp1257", "windows-1257"); |
213 registrar("x-cp1258", "windows-1258"); | 214 registrar("x-cp1258", "windows-1258"); |
214 } | 215 } |
215 | 216 |
216 void TextCodecICU::registerCodecs(TextCodecRegistrar registrar) | 217 void TextCodecICU::registerCodecs(TextCodecRegistrar registrar) |
217 { | 218 { |
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
537 { | 538 { |
538 return encodeCommon(characters, length, handling); | 539 return encodeCommon(characters, length, handling); |
539 } | 540 } |
540 | 541 |
541 CString TextCodecICU::encode(const LChar* characters, size_t length, Unencodable
Handling handling) | 542 CString TextCodecICU::encode(const LChar* characters, size_t length, Unencodable
Handling handling) |
542 { | 543 { |
543 return encodeCommon(characters, length, handling); | 544 return encodeCommon(characters, length, handling); |
544 } | 545 } |
545 | 546 |
546 } // namespace WTF | 547 } // namespace WTF |
OLD | NEW |