/* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ #include #include "convertsimple.hxx" #include "tenchelp.hxx" /* ======================================================================= */ /* This file contain the tables for all 1 byte charsets, for the */ /* following scripts: arabic, hebrew and other scripts in the arabic region */ /* ======================================================================= */ /* IBM-862 */ /* Dos Standard CharSet for Hebrew */ /* 1-Byte, 0x00-0x7F ASCII without exception */ /* Convert-Tables: mappings/vendors/micsft/pc/cp862.txt from 04/24/96 Version 2.00 */ /* Last-Changes from us: */ /* ----------------------------------------------------------------------- */ #define IBM862UNI_START 0x80 #define IBM862UNI_END 0xFF sal_uInt16 const aImplIBM862ToUniTab[IBM862UNI_END - IBM862UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x05D0, 0x05D1, 0x05D2, 0x05D3, 0x05D4, 0x05D5, 0x05D6, 0x05D7, /* 0x80 */ 0x05D8, 0x05D9, 0x05DA, 0x05DB, 0x05DC, 0x05DD, 0x05DE, 0x05DF, /* 0x80 */ 0x05E0, 0x05E1, 0x05E2, 0x05E3, 0x05E4, 0x05E5, 0x05E6, 0x05E7, /* 0x90 */ 0x05E8, 0x05E9, 0x05EA, 0x00A2, 0x00A3, 0x00A5, 0x20A7, 0x0192, /* 0x90 */ 0x00E1, 0x00ED, 0x00F3, 0x00FA, 0x00F1, 0x00D1, 0x00AA, 0x00BA, /* 0xA0 */ 0x00BF, 0x2310, 0x00AC, 0x00BD, 0x00BC, 0x00A1, 0x00AB, 0x00BB, /* 0xA0 */ 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, /* 0xB0 */ 0x2555, 0x2563, 0x2551, 0x2557, 0x255D, 0x255C, 0x255B, 0x2510, /* 0xB0 */ 0x2514, 0x2534, 0x252C, 0x251C, 0x2500, 0x253C, 0x255E, 0x255F, /* 0xC0 */ 0x255A, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256C, 0x2567, /* 0xC0 */ 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256B, /* 0xD0 */ 0x256A, 0x2518, 0x250C, 0x2588, 0x2584, 0x258C, 0x2590, 0x2580, /* 0xD0 */ 0x03B1, 0x00DF, 0x0393, 0x03C0, 0x03A3, 0x03C3, 0x00B5, 0x03C4, /* 0xE0 */ 0x03A6, 0x0398, 0x03A9, 0x03B4, 0x221E, 0x03C6, 0x03B5, 0x2229, /* 0xE0 */ 0x2261, 0x00B1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00F7, 0x2248, /* 0xF0 */ 0x00B0, 0x2219, 0x00B7, 0x221A, 0x207F, 0x00B2, 0x25A0, 0x00A0 /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define IBM862CHAR_START 0x05D0 #define IBM862CHAR_END 0x05EA unsigned char const aImplIBM862ToCharTab[IBM862CHAR_END - IBM862CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x05D0 */ 0x88, 0x89, 0x8A, 0x8B, 0x8C, 0x8D, 0x8E, 0x8F, /* 0x05D0 */ 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x05E0 */ 0x98, 0x99, 0x9A /* 0x05E0 */ }; /* ----------------------------------------------------------------------- */ #define IBM862TOCHARTABEX_COUNT 101 ImplUniCharTabData const aImplIBM862ToCharTabEx[IBM862TOCHARTABEX_COUNT] = { { 0x00A0, 0xFF, 0 }, { 0x00A1, 0xAD, 0 }, { 0x00A2, 0x9B, 0 }, { 0x00A3, 0x9C, 0 }, { 0x00A5, 0x9D, 0 }, { 0x00AA, 0xA6, 0 }, { 0x00AB, 0xAE, 0 }, { 0x00AC, 0xAA, 0 }, { 0x00B0, 0xF8, 0 }, { 0x00B1, 0xF1, 0 }, { 0x00B2, 0xFD, 0 }, { 0x00B5, 0xE6, 0 }, { 0x00B7, 0xFA, 0 }, { 0x00BA, 0xA7, 0 }, { 0x00BB, 0xAF, 0 }, { 0x00BC, 0xAC, 0 }, { 0x00BD, 0xAB, 0 }, { 0x00BF, 0xA8, 0 }, { 0x00D1, 0xA5, 0 }, { 0x00DF, 0xE1, 0 }, { 0x00E1, 0xA0, 0 }, { 0x00ED, 0xA1, 0 }, { 0x00F1, 0xA4, 0 }, { 0x00F3, 0xA2, 0 }, { 0x00F7, 0xF6, 0 }, { 0x00FA, 0xA3, 0 }, { 0x0192, 0x9F, 0 }, { 0x0393, 0xE2, 0 }, { 0x0398, 0xE9, 0 }, { 0x03A3, 0xE4, 0 }, { 0x03A6, 0xE8, 0 }, { 0x03A9, 0xEA, 0 }, { 0x03B1, 0xE0, 0 }, { 0x03B4, 0xEB, 0 }, { 0x03B5, 0xEE, 0 }, { 0x03C0, 0xE3, 0 }, { 0x03C3, 0xE5, 0 }, { 0x03C4, 0xE7, 0 }, { 0x03C6, 0xED, 0 }, { 0x207F, 0xFC, 0 }, { 0x20A7, 0x9E, 0 }, { 0x2219, 0xF9, 0 }, { 0x221A, 0xFB, 0 }, { 0x221E, 0xEC, 0 }, { 0x2229, 0xEF, 0 }, { 0x2248, 0xF7, 0 }, { 0x2261, 0xF0, 0 }, { 0x2264, 0xF3, 0 }, { 0x2265, 0xF2, 0 }, { 0x2310, 0xA9, 0 }, { 0x2320, 0xF4, 0 }, { 0x2321, 0xF5, 0 }, { 0x2500, 0xC4, 0 }, { 0x2502, 0xB3, 0 }, { 0x250C, 0xDA, 0 }, { 0x2510, 0xBF, 0 }, { 0x2514, 0xC0, 0 }, { 0x2518, 0xD9, 0 }, { 0x251C, 0xC3, 0 }, { 0x2524, 0xB4, 0 }, { 0x252C, 0xC2, 0 }, { 0x2534, 0xC1, 0 }, { 0x253C, 0xC5, 0 }, { 0x2550, 0xCD, 0 }, { 0x2551, 0xBA, 0 }, { 0x2552, 0xD5, 0 }, { 0x2553, 0xD6, 0 }, { 0x2554, 0xC9, 0 }, { 0x2555, 0xB8, 0 }, { 0x2556, 0xB7, 0 }, { 0x2557, 0xBB, 0 }, { 0x2558, 0xD4, 0 }, { 0x2559, 0xD3, 0 }, { 0x255A, 0xC8, 0 }, { 0x255B, 0xBE, 0 }, { 0x255C, 0xBD, 0 }, { 0x255D, 0xBC, 0 }, { 0x255E, 0xC6, 0 }, { 0x255F, 0xC7, 0 }, { 0x2560, 0xCC, 0 }, { 0x2561, 0xB5, 0 }, { 0x2562, 0xB6, 0 }, { 0x2563, 0xB9, 0 }, { 0x2564, 0xD1, 0 }, { 0x2565, 0xD2, 0 }, { 0x2566, 0xCB, 0 }, { 0x2567, 0xCF, 0 }, { 0x2568, 0xD0, 0 }, { 0x2569, 0xCA, 0 }, { 0x256A, 0xD8, 0 }, { 0x256B, 0xD7, 0 }, { 0x256C, 0xCE, 0 }, { 0x2580, 0xDF, 0 }, { 0x2584, 0xDC, 0 }, { 0x2588, 0xDB, 0 }, { 0x258C, 0xDD, 0 }, { 0x2590, 0xDE, 0 }, { 0x2591, 0xB0, 0 }, { 0x2592, 0xB1, 0 }, { 0x2593, 0xB2, 0 }, { 0x25A0, 0xFE, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplIBM862ByteCvtData = { aImplIBM862ToUniTab, nullptr, aImplIBM862ToCharTab, nullptr, aImplIBM862ToCharTabEx, IBM862UNI_START, IBM862UNI_END, NOTABUNI_START, NOTABUNI_END, IBM862CHAR_START, IBM862CHAR_END, NOTABCHAR_START, NOTABCHAR_END, IBM862TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplIBM862TextEncodingData = { { &aImplIBM862ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-8", "IBM862", 1, 1, 1, 177, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_MIME | RTL_TEXTENCODING_INFO_R2L }; /* DOS/OS2, SCRIPT_HEBREW, pc code page 862, mac encoding 5 */ /* ======================================================================= */ /* IBM-864 */ /* Dos Standard CharSet for Arabic */ /* 1-Byte, 0x00-0x7F ASCII without exception */ /* Convert-Tables: mappings/vendors/micsft/pc/cp864.txt from 04/24/96 Version 2.00 */ /* Last-Changes from us: */ /* ----------------------------------------------------------------------- */ #define IBM864UNI_START 0x80 #define IBM864UNI_END 0xFE sal_uInt16 const aImplIBM864ToUniTab[IBM864UNI_END - IBM864UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x00B0, 0x00B7, 0x2219, 0x221A, 0x2592, 0x2500, 0x2502, 0x253C, /* 0x80 */ 0x2524, 0x252C, 0x251C, 0x2534, 0x2510, 0x250C, 0x2514, 0x2518, /* 0x80 */ 0x03B2, 0x221E, 0x03C6, 0x00B1, 0x00BD, 0x00BC, 0x2248, 0x00AB, /* 0x90 */ 0x00BB, 0xFEF7, 0xFEF8, 0, 0, 0xFEFB, 0xFEFC, 0, /* 0x90 */ 0x00A0, 0x00AD, 0xFE82, 0x00A3, 0x00A4, 0xFE84, 0, 0, /* 0xA0 */ 0xFE8E, 0xFE8F, 0xFE95, 0xFE99, 0x060C, 0xFE9D, 0xFEA1, 0xFEA5, /* 0xA0 */ 0x0660, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, 0x0666, 0x0667, /* 0xB0 */ 0x0668, 0x0669, 0xFED1, 0x061B, 0xFEB1, 0xFEB5, 0xFEB9, 0x061F, /* 0xB0 */ 0x00A2, 0xFE80, 0xFE81, 0xFE83, 0xFE85, 0xFECA, 0xFE8B, 0xFE8D, /* 0xC0 */ 0xFE91, 0xFE93, 0xFE97, 0xFE9B, 0xFE9F, 0xFEA3, 0xFEA7, 0xFEA9, /* 0xC0 */ 0xFEAB, 0xFEAD, 0xFEAF, 0xFEB3, 0xFEB7, 0xFEBB, 0xFEBF, 0xFEC1, /* 0xD0 */ 0xFEC5, 0xFECB, 0xFECF, 0x00A6, 0x00AC, 0x00F7, 0x00D7, 0xFEC9, /* 0xD0 */ 0x0640, 0xFED3, 0xFED7, 0xFEDB, 0xFEDF, 0xFEE3, 0xFEE7, 0xFEEB, /* 0xE0 */ 0xFEED, 0xFEEF, 0xFEF3, 0xFEBD, 0xFECC, 0xFECE, 0xFECD, 0xFEE1, /* 0xE0 */ 0xFE7D, 0x0651, 0xFEE5, 0xFEE9, 0xFEEC, 0xFEF0, 0xFEF2, 0xFED0, /* 0xF0 */ 0xFED5, 0xFEF5, 0xFEF6, 0xFEDD, 0xFED9, 0xFEF1, 0x25A0 /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define IBM864CHAR_START 0xFE7D #define IBM864CHAR_END 0xFEFC unsigned char const aImplIBM864ToCharTab[IBM864CHAR_END - IBM864CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0xF0, 0, 0, /* 0xFE70 */ 0xC1, 0xC2, 0xA2, 0xC3, 0xA5, 0xC4, 0, 0, /* 0xFE80 */ 0, 0, 0, 0xC6, 0, 0xC7, 0xA8, 0xA9, /* 0xFE80 */ 0, 0xC8, 0, 0xC9, 0, 0xAA, 0, 0xCA, /* 0xFE90 */ 0, 0xAB, 0, 0xCB, 0, 0xAD, 0, 0xCC, /* 0xFE90 */ 0, 0xAE, 0, 0xCD, 0, 0xAF, 0, 0xCE, /* 0xFEA0 */ 0, 0xCF, 0, 0xD0, 0, 0xD1, 0, 0xD2, /* 0xFEA0 */ 0, 0xBC, 0, 0xD3, 0, 0xBD, 0, 0xD4, /* 0xFEB0 */ 0, 0xBE, 0, 0xD5, 0, 0xEB, 0, 0xD6, /* 0xFEB0 */ 0, 0xD7, 0, 0, 0, 0xD8, 0, 0, /* 0xFEC0 */ 0, 0xDF, 0xC5, 0xD9, 0xEC, 0xEE, 0xED, 0xDA, /* 0xFEC0 */ 0xF7, 0xBA, 0, 0xE1, 0, 0xF8, 0, 0xE2, /* 0xFED0 */ 0, 0xFC, 0, 0xE3, 0, 0xFB, 0, 0xE4, /* 0xFED0 */ 0, 0xEF, 0, 0xE5, 0, 0xF2, 0, 0xE6, /* 0xFEE0 */ 0, 0xF3, 0, 0xE7, 0xF4, 0xE8, 0, 0xE9, /* 0xFEE0 */ 0xF5, 0xFD, 0xF6, 0xEA, 0, 0xF9, 0xFA, 0x99, /* 0xFEF0 */ 0x9A, 0, 0, 0x9D, 0x9E /* 0xFEF0 */ }; /* ----------------------------------------------------------------------- */ #define IBM864TOCHARTABEX_COUNT 51 ImplUniCharTabData const aImplIBM864ToCharTabEx[IBM864TOCHARTABEX_COUNT] = { { 0x00A0, 0xA0, 0 }, { 0x00A2, 0xC0, 0 }, { 0x00A3, 0xA3, 0 }, { 0x00A4, 0xA4, 0 }, { 0x00A6, 0xDB, 0 }, { 0x00AB, 0x97, 0 }, { 0x00AC, 0xDC, 0 }, { 0x00AD, 0xA1, 0 }, { 0x00B0, 0x80, 0 }, { 0x00B1, 0x93, 0 }, { 0x00B7, 0x81, 0 }, { 0x00BB, 0x98, 0 }, { 0x00BC, 0x95, 0 }, { 0x00BD, 0x94, 0 }, { 0x00D7, 0xDE, 0 }, { 0x00F7, 0xDD, 0 }, { 0x03B2, 0x90, 0 }, { 0x03C6, 0x92, 0 }, { 0x060C, 0xAC, 0 }, { 0x061B, 0xBB, 0 }, { 0x061F, 0xBF, 0 }, { 0x0640, 0xE0, 0 }, { 0x0651, 0xF1, 0 }, { 0x0660, 0xB0, 0 }, { 0x0661, 0xB1, 0 }, { 0x0662, 0xB2, 0 }, { 0x0663, 0xB3, 0 }, { 0x0664, 0xB4, 0 }, { 0x0665, 0xB5, 0 }, { 0x0666, 0xB6, 0 }, { 0x0667, 0xB7, 0 }, { 0x0668, 0xB8, 0 }, { 0x0669, 0xB9, 0 }, { 0x066A, 0x25, 0 }, { 0x2219, 0x82, 0 }, { 0x221A, 0x83, 0 }, { 0x221E, 0x91, 0 }, { 0x2248, 0x96, 0 }, { 0x2500, 0x85, 0 }, { 0x2502, 0x86, 0 }, { 0x250C, 0x8D, 0 }, { 0x2510, 0x8C, 0 }, { 0x2514, 0x8E, 0 }, { 0x2518, 0x8F, 0 }, { 0x251C, 0x8A, 0 }, { 0x2524, 0x88, 0 }, { 0x252C, 0x89, 0 }, { 0x2534, 0x8B, 0 }, { 0x253C, 0x87, 0 }, { 0x2592, 0x84, 0 }, { 0x25A0, 0xFE, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplIBM864ByteCvtData = { aImplIBM864ToUniTab, nullptr, aImplIBM864ToCharTab, nullptr, aImplIBM864ToCharTabEx, IBM864UNI_START, IBM864UNI_END, NOTABUNI_START, NOTABUNI_END, IBM864CHAR_START, IBM864CHAR_END, NOTABCHAR_START, NOTABCHAR_END, IBM864TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplIBM864TextEncodingData = { { &aImplIBM864ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-6", "IBM864", 1, 1, 1, 178, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_MIME | RTL_TEXTENCODING_INFO_R2L }; /* DOS/OS2, SCRIPT_ARABIC, pc code page 864, mac encoding 4 */ /* ======================================================================= */ /* MS-1255 */ /* Windows Standard CharSet for Hebrew */ /* 1-Byte, 0x00-0x7F ASCII without exception */ /* Convert-Tables: mappings/vendors/micsft/windows/cp1255.txt from 04/15/98 Version 2.01 */ /* Last-Changes from us: */ /* ----------------------------------------------------------------------- */ #define MS1255UNI_START 0x80 #define MS1255UNI_END 0xFF sal_uInt16 const aImplMS1255ToUniTab[MS1255UNI_END - MS1255UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x20AC, 0, 0x201A, 0x0192, 0x201E, 0x2026, 0x2020, 0x2021, /* 0x80 */ 0x02C6, 0x2030, 0, 0x2039, 0, 0, 0, 0, /* 0x80 */ 0, 0x2018, 0x2019, 0x201C, 0x201D, 0x2022, 0x2013, 0x2014, /* 0x90 */ 0x02DC, 0x2122, 0, 0x203A, 0, 0, 0, 0, /* 0x90 */ 0x00A0, 0x00A1, 0x00A2, 0x00A3, 0x20AA, 0x00A5, 0x00A6, 0x00A7, /* 0xA0 */ 0x00A8, 0x00A9, 0x00D7, 0x00AB, 0x00AC, 0x00AD, 0x00AE, 0x00AF, /* 0xA0 */ 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x00B4, 0x00B5, 0x00B6, 0x00B7, /* 0xB0 */ 0x00B8, 0x00B9, 0x00F7, 0x00BB, 0x00BC, 0x00BD, 0x00BE, 0x00BF, /* 0xB0 */ 0x05B0, 0x05B1, 0x05B2, 0x05B3, 0x05B4, 0x05B5, 0x05B6, 0x05B7, /* 0xC0 */ 0x05B8, 0x05B9, 0, 0x05BB, 0x05BC, 0x05BD, 0x05BE, 0x05BF, /* 0xC0 */ 0x05C0, 0x05C1, 0x05C2, 0x05C3, 0x05F0, 0x05F1, 0x05F2, 0x05F3, /* 0xD0 */ 0x05F4, 0, 0, 0, 0, 0, 0, 0, /* 0xD0 */ 0x05D0, 0x05D1, 0x05D2, 0x05D3, 0x05D4, 0x05D5, 0x05D6, 0x05D7, /* 0xE0 */ 0x05D8, 0x05D9, 0x05DA, 0x05DB, 0x05DC, 0x05DD, 0x05DE, 0x05DF, /* 0xE0 */ 0x05E0, 0x05E1, 0x05E2, 0x05E3, 0x05E4, 0x05E5, 0x05E6, 0x05E7, /* 0xF0 */ 0x05E8, 0x05E9, 0x05EA, 0, 0, 0x200E, 0x200F, 0 /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define MS1255CHAR_START 0x05B0 #define MS1255CHAR_END 0x05F4 unsigned char const aImplMS1255ToCharTab[MS1255CHAR_END - MS1255CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, /* 0x05B0 */ 0xC8, 0xC9, 0, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF, /* 0x05B0 */ 0xD0, 0xD1, 0xD2, 0xD3, 0, 0, 0, 0, /* 0x05C0 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0x05C0 */ 0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7, /* 0x05D0 */ 0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF, /* 0x05D0 */ 0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, 0xF6, 0xF7, /* 0x05E0 */ 0xF8, 0xF9, 0xFA, 0, 0, 0, 0, 0, /* 0x05E0 */ 0xD4, 0xD5, 0xD6, 0xD7, 0xD8 /* 0x05F0 */ }; /* ----------------------------------------------------------------------- */ #define MS1255TOCHARTABEX_COUNT 54 ImplUniCharTabData const aImplMS1255ToCharTabEx[MS1255TOCHARTABEX_COUNT] = { { 0x00A0, 0xA0, 0 }, { 0x00A1, 0xA1, 0 }, { 0x00A2, 0xA2, 0 }, { 0x00A3, 0xA3, 0 }, { 0x00A5, 0xA5, 0 }, { 0x00A6, 0xA6, 0 }, { 0x00A7, 0xA7, 0 }, { 0x00A8, 0xA8, 0 }, { 0x00A9, 0xA9, 0 }, { 0x00AB, 0xAB, 0 }, { 0x00AC, 0xAC, 0 }, { 0x00AD, 0xAD, 0 }, { 0x00AE, 0xAE, 0 }, { 0x00AF, 0xAF, 0 }, { 0x00B0, 0xB0, 0 }, { 0x00B1, 0xB1, 0 }, { 0x00B2, 0xB2, 0 }, { 0x00B3, 0xB3, 0 }, { 0x00B4, 0xB4, 0 }, { 0x00B5, 0xB5, 0 }, { 0x00B6, 0xB6, 0 }, { 0x00B7, 0xB7, 0 }, { 0x00B8, 0xB8, 0 }, { 0x00B9, 0xB9, 0 }, { 0x00BB, 0xBB, 0 }, { 0x00BC, 0xBC, 0 }, { 0x00BD, 0xBD, 0 }, { 0x00BE, 0xBE, 0 }, { 0x00BF, 0xBF, 0 }, { 0x00D7, 0xAA, 0 }, { 0x00F7, 0xBA, 0 }, { 0x0192, 0x83, 0 }, { 0x02C6, 0x88, 0 }, { 0x02DC, 0x98, 0 }, { 0x200E, 0xFD, 0 }, { 0x200F, 0xFE, 0 }, { 0x2013, 0x96, 0 }, { 0x2014, 0x97, 0 }, { 0x2018, 0x91, 0 }, { 0x2019, 0x92, 0 }, { 0x201A, 0x82, 0 }, { 0x201C, 0x93, 0 }, { 0x201D, 0x94, 0 }, { 0x201E, 0x84, 0 }, { 0x2020, 0x86, 0 }, { 0x2021, 0x87, 0 }, { 0x2022, 0x95, 0 }, { 0x2026, 0x85, 0 }, { 0x2030, 0x89, 0 }, { 0x2039, 0x8B, 0 }, { 0x203A, 0x9B, 0 }, { 0x20AA, 0xA4, 0 }, { 0x20AC, 0x80, 0 }, { 0x2122, 0x99, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplMS1255ByteCvtData = { aImplMS1255ToUniTab, nullptr, aImplMS1255ToCharTab, nullptr, aImplMS1255ToCharTabEx, MS1255UNI_START, MS1255UNI_END, NOTABUNI_START, NOTABUNI_END, MS1255CHAR_START, MS1255CHAR_END, NOTABCHAR_START, NOTABCHAR_END, MS1255TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplMS1255TextEncodingData = { { &aImplMS1255ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-8", "windows-1255", 1, 1, 1, 177, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_MIME | RTL_TEXTENCODING_INFO_R2L }; /* WIN, SCRIPT_HEBREW, pc code page 862, mac encoding 5 */ /* ======================================================================= */ /* MS-1256 */ /* Windows Standard CharSet for Arabic */ /* 1-Byte, 0x00-0x7F ASCII without exception */ /* Convert-Tables: mappings/vendors/micsft/windows/cp1256.txt from 01/5/99 Version 2.01 */ /* ----------------------------------------------------------------------- */ #define MS1256UNI_START 0x80 #define MS1256UNI_END 0xFF sal_uInt16 const aImplMS1256ToUniTab[MS1256UNI_END - MS1256UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x20AC, 0x067E, 0x201A, 0x0192, 0x201E, 0x2026, 0x2020, 0x2021, /* 0x80 */ 0x02C6, 0x2030, 0x0679, 0x2039, 0x0152, 0x0686, 0x0698, 0x0688, /* 0x80 */ 0x06AF, 0x2018, 0x2019, 0x201C, 0x201D, 0x2022, 0x2013, 0x2014, /* 0x90 */ 0x06A9, 0x2122, 0x0691, 0x203A, 0x0153, 0x200C, 0x200D, 0x06BA, /* 0x90 */ 0x00A0, 0x060C, 0x00A2, 0x00A3, 0x00A4, 0x00A5, 0x00A6, 0x00A7, /* 0xA0 */ 0x00A8, 0x00A9, 0x06BE, 0x00AB, 0x00AC, 0x00AD, 0x00AE, 0x00AF, /* 0xA0 */ 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x00B4, 0x00B5, 0x00B6, 0x00B7, /* 0xB0 */ 0x00B8, 0x00B9, 0x061B, 0x00BB, 0x00BC, 0x00BD, 0x00BE, 0x061F, /* 0xB0 */ 0x06C1, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, /* 0xC0 */ 0x0628, 0x0629, 0x062A, 0x062B, 0x062C, 0x062D, 0x062E, 0x062F, /* 0xC0 */ 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x00D7, /* 0xD0 */ 0x0637, 0x0638, 0x0639, 0x063A, 0x0640, 0x0641, 0x0642, 0x0643, /* 0xD0 */ 0x00E0, 0x0644, 0x00E2, 0x0645, 0x0646, 0x0647, 0x0648, 0x00E7, /* 0xE0 */ 0x00E8, 0x00E9, 0x00EA, 0x00EB, 0x0649, 0x064A, 0x00EE, 0x00EF, /* 0xE0 */ 0x064B, 0x064C, 0x064D, 0x064E, 0x00F4, 0x064F, 0x0650, 0x00F7, /* 0xF0 */ 0x0651, 0x00F9, 0x0652, 0x00FB, 0x00FC, 0x200E, 0x200F, 0x06D2 /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define MS1256CHAR_START 0x061B #define MS1256CHAR_END 0x0652 unsigned char const aImplMS1256ToCharTab[MS1256CHAR_END - MS1256CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0xBA, 0, 0, 0, 0xBF, /* 0x0610 */ 0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, /* 0x0620 */ 0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF, /* 0x0620 */ 0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0xD5, 0xD6, 0xD8, /* 0x0630 */ 0xD9, 0xDA, 0xDB, 0, 0, 0, 0, 0, /* 0x0630 */ 0xDC, 0xDD, 0xDE, 0xDF, 0xE1, 0xE3, 0xE4, 0xE5, /* 0x0640 */ 0xE6, 0xEC, 0xED, 0xF0, 0xF1, 0xF2, 0xF3, 0xF5, /* 0x0640 */ 0xF6, 0xF8, 0xFA /* 0x0650 */ }; /* ----------------------------------------------------------------------- */ #define MS1256TOCHARTABEX_COUNT 81 ImplUniCharTabData const aImplMS1256ToCharTabEx[MS1256TOCHARTABEX_COUNT] = { { 0x00A0, 0xA0, 0 }, { 0x00A2, 0xA2, 0 }, { 0x00A3, 0xA3, 0 }, { 0x00A4, 0xA4, 0 }, { 0x00A5, 0xA5, 0 }, { 0x00A6, 0xA6, 0 }, { 0x00A7, 0xA7, 0 }, { 0x00A8, 0xA8, 0 }, { 0x00A9, 0xA9, 0 }, { 0x00AB, 0xAB, 0 }, { 0x00AC, 0xAC, 0 }, { 0x00AD, 0xAD, 0 }, { 0x00AE, 0xAE, 0 }, { 0x00AF, 0xAF, 0 }, { 0x00B0, 0xB0, 0 }, { 0x00B1, 0xB1, 0 }, { 0x00B2, 0xB2, 0 }, { 0x00B3, 0xB3, 0 }, { 0x00B4, 0xB4, 0 }, { 0x00B5, 0xB5, 0 }, { 0x00B6, 0xB6, 0 }, { 0x00B7, 0xB7, 0 }, { 0x00B8, 0xB8, 0 }, { 0x00B9, 0xB9, 0 }, { 0x00BB, 0xBB, 0 }, { 0x00BC, 0xBC, 0 }, { 0x00BD, 0xBD, 0 }, { 0x00BE, 0xBE, 0 }, { 0x00D7, 0xD7, 0 }, { 0x00E0, 0xE0, 0 }, { 0x00E2, 0xE2, 0 }, { 0x00E7, 0xE7, 0 }, { 0x00E8, 0xE8, 0 }, { 0x00E9, 0xE9, 0 }, { 0x00EA, 0xEA, 0 }, { 0x00EB, 0xEB, 0 }, { 0x00EE, 0xEE, 0 }, { 0x00EF, 0xEF, 0 }, { 0x00F4, 0xF4, 0 }, { 0x00F7, 0xF7, 0 }, { 0x00F9, 0xF9, 0 }, { 0x00FB, 0xFB, 0 }, { 0x00FC, 0xFC, 0 }, { 0x0152, 0x8C, 0 }, { 0x0153, 0x9C, 0 }, { 0x0192, 0x83, 0 }, { 0x02C6, 0x88, 0 }, { 0x060C, 0xA1, 0 }, { 0x0679, 0x8A, 0 }, { 0x067E, 0x81, 0 }, { 0x0686, 0x8D, 0 }, { 0x0688, 0x8F, 0 }, { 0x0691, 0x9A, 0 }, { 0x0698, 0x8E, 0 }, { 0x06A9, 0x98, 0 }, { 0x06AF, 0x90, 0 }, { 0x06BA, 0x9F, 0 }, { 0x06BE, 0xAA, 0 }, { 0x06C1, 0xC0, 0 }, { 0x06D2, 0xFF, 0 }, { 0x200C, 0x9D, 0 }, { 0x200D, 0x9E, 0 }, { 0x200E, 0xFD, 0 }, { 0x200F, 0xFE, 0 }, { 0x2013, 0x96, 0 }, { 0x2014, 0x97, 0 }, { 0x2018, 0x91, 0 }, { 0x2019, 0x92, 0 }, { 0x201A, 0x82, 0 }, { 0x201C, 0x93, 0 }, { 0x201D, 0x94, 0 }, { 0x201E, 0x84, 0 }, { 0x2020, 0x86, 0 }, { 0x2021, 0x87, 0 }, { 0x2022, 0x95, 0 }, { 0x2026, 0x85, 0 }, { 0x2030, 0x89, 0 }, { 0x2039, 0x8B, 0 }, { 0x203A, 0x9B, 0 }, { 0x20AC, 0x80, 0 }, { 0x2122, 0x99, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplMS1256ByteCvtData = { aImplMS1256ToUniTab, nullptr, aImplMS1256ToCharTab, nullptr, aImplMS1256ToCharTabEx, MS1256UNI_START, MS1256UNI_END, NOTABUNI_START, NOTABUNI_END, MS1256CHAR_START, MS1256CHAR_END, NOTABCHAR_START, NOTABCHAR_END, MS1256TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplMS1256TextEncodingData = { { &aImplMS1256ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-6", "windows-1256", 1, 1, 1, 178, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_MIME | RTL_TEXTENCODING_INFO_R2L }; /* WIN, SCRIPT_ARABIC, pc code page 864, mac encoding 4 */ /* ======================================================================= */ /* ISO-8859-6 */ /* Unix Standard for Arabic */ /* 1-Byte, 0x00-0x7F ASCII without exception, 0x80-0x9F control character like in Unicode */ /* Convert-Tables: mappings/iso8859/8859-6.txt from 07/27/99 Version 1.0 (based on Unicode 3.0) */ /* Last-Changes from us: */ /* !!! 0x30-0x39 are Arabic numbers and should normally be mapped to 0x0660-0x0669 !!! */ #define ISO88596UNI_START 0xA0 #define ISO88596UNI_END 0xF2 sal_uInt16 const aImplISO88596ToUniTab[ISO88596UNI_END - ISO88596UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x00A0, 0, 0, 0, 0x00A4, 0, 0, 0, /* 0xA0 */ 0, 0, 0, 0, 0x060C, 0x00AD, 0, 0, /* 0xA0 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0xB0 */ 0, 0, 0, 0x061B, 0, 0, 0, 0x061F, /* 0xB0 */ 0, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, /* 0xC0 */ 0x0628, 0x0629, 0x062A, 0x062B, 0x062C, 0x062D, 0x062E, 0x062F, /* 0xC0 */ 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, /* 0xD0 */ 0x0638, 0x0639, 0x063A, 0, 0, 0, 0, 0, /* 0xD0 */ 0x0640, 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, /* 0xE0 */ 0x0648, 0x0649, 0x064A, 0x064B, 0x064C, 0x064D, 0x064E, 0x064F, /* 0xE0 */ 0x0650, 0x0651, 0x0652 /* 0xF0 */ /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define ISO88596CHAR_START 0x061B #define ISO88596CHAR_END 0x0669 unsigned char const aImplISO88596ToCharTab[ISO88596CHAR_END - ISO88596CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0xBB, 0, 0, 0, 0xBF, /* 0x0610 */ 0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, /* 0x0620 */ 0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF, /* 0x0620 */ 0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0xD5, 0xD6, 0xD7, /* 0x0630 */ 0xD8, 0xD9, 0xDA, 0, 0, 0, 0, 0, /* 0x0630 */ 0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7, /* 0x0640 */ 0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF, /* 0x0640 */ 0xF0, 0xF1, 0xF2, 0, 0, 0, 0, 0, /* 0x0650 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0650 */ 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, /* 0x0660 */ 0x38, 0x39 /* 0x0660 */ }; /* ----------------------------------------------------------------------- */ #define ISO88596TOCHARTABEX_COUNT 4 ImplUniCharTabData const aImplISO88596ToCharTabEx[ISO88596TOCHARTABEX_COUNT] = { { 0x00A0, 0xA0, 0 }, { 0x00A4, 0xA4, 0 }, { 0x00AD, 0xAD, 0 }, { 0x060C, 0xAC, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplISO88596ByteCvtData = { aImplISO88596ToUniTab, aImpl8090SameToUniTab, aImplISO88596ToCharTab, aImpl8090SameToCharTab, aImplISO88596ToCharTabEx, ISO88596UNI_START, ISO88596UNI_END, SAME8090UNI_START, SAME8090UNI_END, ISO88596CHAR_START, ISO88596CHAR_END, SAME8090CHAR_START, SAME8090CHAR_END, ISO88596TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplISO88596TextEncodingData = { { &aImplISO88596ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-6", "ISO-8859-6", 1, 1, 1, 178, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_R2L | RTL_TEXTENCODING_INFO_MIME }; /* SCRIPT_ARABIC, pc code page 864, mac encoding 4 */ /* ======================================================================= */ /* ISO-8859-8 */ /* Unix Standard for Hebrew */ /* 1-Byte, 0x00-0x7F ASCII without exception, 0x80-0x9F control character like in Unicode */ /* Convert-Tables: mappings/iso8859/8859-8.txt from 2000-Jan-03 Version 1.1 (based on Unicode 3.0) */ #define ISO88598UNI_START 0xA0 #define ISO88598UNI_END 0xFE sal_uInt16 const aImplISO88598ToUniTab[ISO88598UNI_END - ISO88598UNI_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0x00A0, 0, 0x00A2, 0x00A3, 0x00A4, 0x00A5, 0x00A6, 0x00A7, /* 0xA0 */ 0x00A8, 0x00A9, 0x00D7, 0x00AB, 0x00AC, 0x00AD, 0x00AE, 0x00AF, /* 0xA0 */ 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x00B4, 0x00B5, 0x00B6, 0x00B7, /* 0xB0 */ 0x00B8, 0x00B9, 0x00F7, 0x00BB, 0x00BC, 0x00BD, 0x00BE, 0, /* 0xB0 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0xC0 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0xC0 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 0xD0 */ 0, 0, 0, 0, 0, 0, 0, 0x2017, /* 0xD0 */ 0x05D0, 0x05D1, 0x05D2, 0x05D3, 0x05D4, 0x05D5, 0x05D6, 0x05D7, /* 0xE0 */ 0x05D8, 0x05D9, 0x05DA, 0x05DB, 0x05DC, 0x05DD, 0x05DE, 0x05DF, /* 0xE0 */ 0x05E0, 0x05E1, 0x05E2, 0x05E3, 0x05E4, 0x05E5, 0x05E6, 0x05E7, /* 0xF0 */ 0x05E8, 0x05E9, 0x05EA, 0, 0, 0x200E, 0x200F /* 0xF0 */ }; /* ----------------------------------------------------------------------- */ #define ISO88598CHAR_START 0x05D0 #define ISO88598CHAR_END 0x05EA unsigned char const aImplISO88598ToCharTab[ISO88598CHAR_END - ISO88598CHAR_START + 1] = { /* 0 1 2 3 4 5 6 7 */ /* 8 9 A B C D E F */ 0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7, /* 0x05D0 */ 0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF, /* 0x05D0 */ 0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, 0xF6, 0xF7, /* 0x05E0 */ 0xF8, 0xF9, 0xFA /* 0x05E0 */ }; /* ----------------------------------------------------------------------- */ #define ISO88598TOCHARTABEX_COUNT 33 ImplUniCharTabData const aImplISO88598ToCharTabEx[ISO88598TOCHARTABEX_COUNT] = { { 0x00A0, 0xA0, 0 }, { 0x00A2, 0xA2, 0 }, { 0x00A3, 0xA3, 0 }, { 0x00A4, 0xA4, 0 }, { 0x00A5, 0xA5, 0 }, { 0x00A6, 0xA6, 0 }, { 0x00A7, 0xA7, 0 }, { 0x00A8, 0xA8, 0 }, { 0x00A9, 0xA9, 0 }, { 0x00AB, 0xAB, 0 }, { 0x00AC, 0xAC, 0 }, { 0x00AD, 0xAD, 0 }, { 0x00AE, 0xAE, 0 }, { 0x00AF, 0xAF, 0 }, { 0x00B0, 0xB0, 0 }, { 0x00B1, 0xB1, 0 }, { 0x00B2, 0xB2, 0 }, { 0x00B3, 0xB3, 0 }, { 0x00B4, 0xB4, 0 }, { 0x00B5, 0xB5, 0 }, { 0x00B6, 0xB6, 0 }, { 0x00B7, 0xB7, 0 }, { 0x00B8, 0xB8, 0 }, { 0x00B9, 0xB9, 0 }, { 0x00BB, 0xBB, 0 }, { 0x00BC, 0xBC, 0 }, { 0x00BD, 0xBD, 0 }, { 0x00BE, 0xBE, 0 }, { 0x00D7, 0xAA, 0 }, { 0x00F7, 0xBA, 0 }, { 0x200E, 0xFD, 0 }, { 0x200F, 0xFE, 0 }, { 0x2017, 0xDF, 0 } }; /* ----------------------------------------------------------------------- */ ImplByteConvertData const aImplISO88598ByteCvtData = { aImplISO88598ToUniTab, aImpl8090SameToUniTab, aImplISO88598ToCharTab, aImpl8090SameToCharTab, aImplISO88598ToCharTabEx, ISO88598UNI_START, ISO88598UNI_END, SAME8090UNI_START, SAME8090UNI_END, ISO88598CHAR_START, ISO88598CHAR_END, SAME8090CHAR_START, SAME8090CHAR_END, ISO88598TOCHARTABEX_COUNT }; /* ----------------------------------------------------------------------- */ ImplTextEncodingData const aImplISO88598TextEncodingData = { { &aImplISO88598ByteCvtData, sal::detail::textenc::convertCharToUnicode, sal::detail::textenc::convertUnicodeToChar, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr }, "iso8859-8", "ISO-8859-8", 1, 1, 1, 177, RTL_TEXTENCODING_INFO_ASCII | RTL_TEXTENCODING_INFO_R2L | RTL_TEXTENCODING_INFO_MIME }; /* SCRIPT_HEBREW, pc code page 862, mac encoding 5 */ 3-2 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
path: root/include/postwin.h
AgeCommit message (Expand)Author