MacRomanEncoding.java
9.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
/*
* Decompiled with CFR 0_118.
*
* Could not load the following classes:
* com.adobe.internal.pdftoolkit.core.types.ASName
*/
package com.adobe.internal.pdftoolkit.pdf.graphics.font.encodings;
import com.adobe.internal.pdftoolkit.core.types.ASName;
import com.adobe.internal.pdftoolkit.pdf.graphics.font.encodings.CharSetEncoding;
public class MacRomanEncoding
extends CharSetEncoding {
private static final char[] macRomanEncoding = new char[]{'\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', '\ufffd', ' ', '!', '\"', '#', '$', '%', '&', '\'', '(', ')', '*', '+', ',', '-', '.', '/', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', ':', ';', '<', '=', '>', '?', '@', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '[', '\\', ']', '^', '_', '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '~', '\ufffd', '\u00c4', '\u00c5', '\u00c7', '\u00c9', '\u00d1', '\u00d6', '\u00dc', '\u00e1', '\u00e0', '\u00e2', '\u00e4', '\u00e3', '\u00e5', '\u00e7', '\u00e9', '\u00e8', '\u00ea', '\u00eb', '\u00ed', '\u00ec', '\u00ee', '\u00ef', '\u00f1', '\u00f3', '\u00f2', '\u00f4', '\u00f6', '\u00f5', '\u00fa', '\u00f9', '\u00fb', '\u00fc', '\u2020', '\u00b0', '\u00a2', '\u00a3', '\u00a7', '\u2022', '\u00b6', '\u00df', '\u00ae', '\u00a9', '\u2122', '\u00b4', '\u00a8', '\u2260', '\u00c6', '\u00d8', '\u221e', '\u00b1', '\u2264', '\u2265', '\u00a5', '\u00b5', '\u2202', '\u2211', '\u220f', '\u03c0', '\u222b', '\u00aa', '\u00ba', '\u2126', '\u00e6', '\u00f8', '\u00bf', '\u00a1', '\u00ac', '\u221a', '\u0192', '\u2248', '\u2206', '\u00ab', '\u00bb', '\u2026', ' ', '\u00c0', '\u00c3', '\u00d5', '\u0152', '\u0153', '\u2013', '\u2014', '\u201c', '\u201d', '\u2018', '\u2019', '\u00f7', '\u25ca', '\u00ff', '\u0178', '\u2044', '\u00a4', '\u2039', '\u203a', '\ufb01', '\ufb02', '\u2021', '\u00b7', '\u201a', '\u201e', '\u2030', '\u00c2', '\u00ca', '\u00c1', '\u00cb', '\u00c8', '\u00cd', '\u00ce', '\u00cf', '\u00cc', '\u00d3', '\u00d4', '\uf8ff', '\u00d2', '\u00da', '\u00db', '\u00d9', '\u0131', '\u02c6', '\u0303', '\u00af', '\u02d8', '\u02d9', '\u02da', '\u00b8', '\u02dd', '\u0328', '\u030d', '\ue900'};
private static final String[] macRomanEncodingByName = new String[]{".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", "space", "exclam", "quotedbl", "numbersign", "dollar", "percent", "ampersand", "quotesingle", "parenleft", "parenright", "asterisk", "plus", "comma", "hyphen", "period", "slash", "zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "colon", "semicolon", "less", "equal", "greater", "question", "at", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "bracketleft", "backslash", "bracketright", "asciicircum", "underscore", "grave", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "braceleft", "bar", "braceright", "asciitilde", ".notdef", "Adieresis", "Aring", "Ccedilla", "Eacute", "Ntilde", "Odieresis", "Udieresis", "aacute", "agrave", "acircumflex", "adieresis", "atilde", "aring", "ccedilla", "eacute", "egrave", "ecircumflex", "edieresis", "iacute", "igrave", "icircumflex", "idieresis", "ntilde", "oacute", "ograve", "ocircumflex", "odieresis", "otilde", "uacute", "ugrave", "ucircumflex", "udieresis", "dagger", "degree", "cent", "sterling", "section", "bullet", "paragraph", "germandbls", "registered", "copyright", "trademark", "acute", "dieresis", ".notdef", "AE", "Oslash", ".notdef", "plusminus", ".notdef", ".notdef", "yen", "mu", ".notdef", ".notdef", ".notdef", ".notdef", ".notdef", "ordfeminine", "ordmasculine", ".notdef", "ae", "oslash", "questiondown", "exclamdown", "logicalnot", ".notdef", "florin", ".notdef", ".notdef", "guillemotleft", "guillemotright", "ellipsis", "space", "Agrave", "Atilde", "Otilde", "OE", "oe", "endash", "emdash", "quotedblleft", "quotedblright", "quoteleft", "quoteright", "divide", ".notdef", "ydieresis", "Ydieresis", "fraction", "currency", "guilsinglleft", "guilsinglright", "fi", "fl", "daggerdbl", "periodcentered", "quotesinglbase", "quotedblbase", "perthousand", "Acircumflex", "Ecircumflex", "Aacute", "Edieresis", "Egrave", "Iacute", "Icircumflex", "Idieresis", "Igrave", "Oacute", "Ocircumflex", ".notdef", "Ograve", "Uacute", "Ucircumflex", "Ugrave", "dotlessi", "circumflex", "tilde", "macron", "breve", "dotaccent", "ring", "cedilla", "hungarumlaut", "ogonek", "caron"};
private static final short[] macRomanCharIdsWithUnicodeSorted = new short[]{32, 202, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 193, 162, 163, 219, 180, 164, 172, 169, 187, 199, 194, 168, 248, 161, 177, 171, 181, 166, 225, 252, 188, 200, 192, 203, 231, 229, 204, 128, 128, 129, 174, 130, 233, 131, 230, 232, 237, 234, 235, 236, 132, 241, 238, 239, 205, 133, 175, 244, 242, 243, 134, 167, 136, 135, 137, 139, 138, 140, 190, 141, 143, 142, 144, 145, 147, 146, 148, 149, 150, 152, 151, 153, 155, 154, 214, 191, 157, 156, 158, 159, 216, 245, 206, 207, 217, 196, 246, 249, 250, 251, 253, 247, 255, 254, 185, 208, 209, 212, 213, 226, 210, 211, 227, 160, 224, 165, 201, 228, 220, 221, 218, 170, 189, 182, 198, 184, 183, 195, 176, 186, 197, 173, 178, 179, 215, 240, 222, 223, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 127};
private static final short[] macRomanCharIdsWithGlyphNamesSorted = new short[]{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 127, 173, 176, 178, 179, 182, 183, 184, 185, 186, 189, 195, 197, 198, 215, 240, 65, 174, 231, 229, 128, 203, 129, 204, 66, 67, 130, 68, 69, 131, 230, 232, 233, 70, 71, 72, 73, 234, 235, 236, 237, 74, 75, 76, 77, 78, 132, 79, 206, 238, 239, 133, 241, 175, 205, 80, 81, 82, 83, 84, 85, 242, 243, 134, 244, 86, 87, 88, 89, 217, 90, 97, 135, 137, 171, 138, 190, 136, 38, 140, 94, 126, 42, 64, 139, 98, 92, 124, 123, 125, 91, 93, 249, 165, 99, 255, 141, 252, 162, 246, 58, 44, 169, 219, 100, 160, 224, 161, 172, 214, 36, 250, 245, 101, 142, 144, 145, 143, 56, 201, 209, 208, 61, 33, 193, 102, 222, 53, 223, 196, 52, 218, 103, 167, 96, 62, 199, 200, 220, 221, 104, 253, 45, 105, 146, 148, 149, 147, 106, 107, 108, 60, 194, 109, 248, 181, 110, 57, 150, 35, 111, 151, 153, 154, 207, 254, 152, 49, 187, 188, 191, 155, 112, 166, 40, 41, 37, 46, 225, 228, 43, 177, 113, 63, 192, 34, 227, 210, 211, 212, 213, 226, 39, 114, 168, 251, 115, 164, 59, 55, 54, 47, 32, 202, 163, 116, 51, 247, 170, 50, 117, 156, 158, 159, 157, 95, 118, 119, 120, 121, 216, 180, 122, 48};
private static final String[] augmentedMacRomanEncodingByName = new String[256];
private static final MacRomanEncoding instance;
private MacRomanEncoding(char[] toUnicodeMap, String[] toGlyphNameMap, short[] charIdsWithGlyphNamesSorted, short[] macRomanCharIdsWithUnicodeSorted) {
super(ASName.k_MacRomanEncoding, toUnicodeMap, toGlyphNameMap, charIdsWithGlyphNamesSorted, macRomanCharIdsWithUnicodeSorted);
}
public static CharSetEncoding getEncoding() {
return instance;
}
public static String getGlyphNameInAugmentedMacRomanEncoding(int index) {
if (index > 255 || index < 0) {
throw new IllegalArgumentException("Invalid index value");
}
return augmentedMacRomanEncodingByName[index];
}
static {
System.arraycopy(macRomanEncodingByName, 0, augmentedMacRomanEncodingByName, 0, 256);
MacRomanEncoding.augmentedMacRomanEncodingByName[173] = "notequal";
MacRomanEncoding.augmentedMacRomanEncodingByName[176] = "infinity";
MacRomanEncoding.augmentedMacRomanEncodingByName[178] = "lessequal";
MacRomanEncoding.augmentedMacRomanEncodingByName[179] = "greaterequal";
MacRomanEncoding.augmentedMacRomanEncodingByName[182] = "partialdiff";
MacRomanEncoding.augmentedMacRomanEncodingByName[183] = "summation";
MacRomanEncoding.augmentedMacRomanEncodingByName[184] = "product";
MacRomanEncoding.augmentedMacRomanEncodingByName[185] = "pi";
MacRomanEncoding.augmentedMacRomanEncodingByName[186] = "integral";
MacRomanEncoding.augmentedMacRomanEncodingByName[189] = "Omega";
MacRomanEncoding.augmentedMacRomanEncodingByName[195] = "radical";
MacRomanEncoding.augmentedMacRomanEncodingByName[197] = "approxequal";
MacRomanEncoding.augmentedMacRomanEncodingByName[198] = "Delta";
MacRomanEncoding.augmentedMacRomanEncodingByName[215] = "lozenge";
MacRomanEncoding.augmentedMacRomanEncodingByName[219] = "Euro";
MacRomanEncoding.augmentedMacRomanEncodingByName[240] = "apple";
instance = new MacRomanEncoding(macRomanEncoding, macRomanEncodingByName, macRomanCharIdsWithGlyphNamesSorted, macRomanCharIdsWithUnicodeSorted);
}
}