summaryrefslogtreecommitdiff
path: root/tex/context/base/font-otr.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/font-otr.lua')
-rw-r--r--tex/context/base/font-otr.lua727
1 files changed, 381 insertions, 346 deletions
diff --git a/tex/context/base/font-otr.lua b/tex/context/base/font-otr.lua
index 0f22fae5d..49b4565c6 100644
--- a/tex/context/base/font-otr.lua
+++ b/tex/context/base/font-otr.lua
@@ -258,334 +258,334 @@ local languages = {
-- english can stay:
macintosh = {
[ 0] = "english",
- [ 1] = "french",
- [ 2] = "german",
- [ 3] = "italian",
- [ 4] = "dutch",
- [ 5] = "swedish",
- [ 6] = "spanish",
- [ 7] = "danish",
- [ 8] = "portuguese",
- [ 9] = "norwegian",
- [ 10] = "hebrew",
- [ 11] = "japanese",
- [ 12] = "arabic",
- [ 13] = "finnish",
- [ 14] = "greek",
- [ 15] = "icelandic",
- [ 16] = "maltese",
- [ 17] = "turkish",
- [ 18] = "croatian",
- [ 19] = "chinese (traditional)",
- [ 20] = "urdu",
- [ 21] = "hindi",
- [ 22] = "thai",
- [ 23] = "korean",
- [ 24] = "lithuanian",
- [ 25] = "polish",
- [ 26] = "hungarian",
- [ 27] = "estonian",
- [ 28] = "latvian",
- [ 29] = "sami",
- [ 30] = "faroese",
- [ 31] = "farsi/persian",
- [ 32] = "russian",
- [ 33] = "chinese (simplified)",
- [ 34] = "flemish",
- [ 35] = "irish gaelic",
- [ 36] = "albanian",
- [ 37] = "romanian",
- [ 38] = "czech",
- [ 39] = "slovak",
- [ 40] = "slovenian",
- [ 41] = "yiddish",
- [ 42] = "serbian",
- [ 43] = "macedonian",
- [ 44] = "bulgarian",
- [ 45] = "ukrainian",
- [ 46] = "byelorussian",
- [ 47] = "uzbek",
- [ 48] = "kazakh",
- [ 49] = "azerbaijani (cyrillic script)",
- [ 50] = "azerbaijani (arabic script)",
- [ 51] = "armenian",
- [ 52] = "georgian",
- [ 53] = "moldavian",
- [ 54] = "kirghiz",
- [ 55] = "tajiki",
- [ 56] = "turkmen",
- [ 57] = "mongolian (mongolian script)",
- [ 58] = "mongolian (cyrillic script)",
- [ 59] = "pashto",
- [ 60] = "kurdish",
- [ 61] = "kashmiri",
- [ 62] = "sindhi",
- [ 63] = "tibetan",
- [ 64] = "nepali",
- [ 65] = "sanskrit",
- [ 66] = "marathi",
- [ 67] = "bengali",
- [ 68] = "assamese",
- [ 69] = "gujarati",
- [ 70] = "punjabi",
- [ 71] = "oriya",
- [ 72] = "malayalam",
- [ 73] = "kannada",
- [ 74] = "tamil",
- [ 75] = "telugu",
- [ 76] = "sinhalese",
- [ 77] = "burmese",
- [ 78] = "khmer",
- [ 79] = "lao",
- [ 80] = "vietnamese",
- [ 81] = "indonesian",
- [ 82] = "tagalong",
- [ 83] = "malay (roman script)",
- [ 84] = "malay (arabic script)",
- [ 85] = "amharic",
- [ 86] = "tigrinya",
- [ 87] = "galla",
- [ 88] = "somali",
- [ 89] = "swahili",
- [ 90] = "kinyarwanda/ruanda",
- [ 91] = "rundi",
- [ 92] = "nyanja/chewa",
- [ 93] = "malagasy",
- [ 94] = "esperanto",
- [128] = "welsh",
- [129] = "basque",
- [130] = "catalan",
- [131] = "latin",
- [132] = "quenchua",
- [133] = "guarani",
- [134] = "aymara",
- [135] = "tatar",
- [136] = "uighur",
- [137] = "dzongkha",
- [138] = "javanese (roman script)",
- [139] = "sundanese (roman script)",
- [140] = "galician",
- [141] = "afrikaans",
- [142] = "breton",
- [143] = "inuktitut",
- [144] = "scottish gaelic",
- [145] = "manx gaelic",
- [146] = "irish gaelic (with dot above)",
- [147] = "tongan",
- [148] = "greek (polytonic)",
- [149] = "greenlandic",
- [150] = "azerbaijani (roman script)",
+ -- [ 1] = "french",
+ -- [ 2] = "german",
+ -- [ 3] = "italian",
+ -- [ 4] = "dutch",
+ -- [ 5] = "swedish",
+ -- [ 6] = "spanish",
+ -- [ 7] = "danish",
+ -- [ 8] = "portuguese",
+ -- [ 9] = "norwegian",
+ -- [ 10] = "hebrew",
+ -- [ 11] = "japanese",
+ -- [ 12] = "arabic",
+ -- [ 13] = "finnish",
+ -- [ 14] = "greek",
+ -- [ 15] = "icelandic",
+ -- [ 16] = "maltese",
+ -- [ 17] = "turkish",
+ -- [ 18] = "croatian",
+ -- [ 19] = "chinese (traditional)",
+ -- [ 20] = "urdu",
+ -- [ 21] = "hindi",
+ -- [ 22] = "thai",
+ -- [ 23] = "korean",
+ -- [ 24] = "lithuanian",
+ -- [ 25] = "polish",
+ -- [ 26] = "hungarian",
+ -- [ 27] = "estonian",
+ -- [ 28] = "latvian",
+ -- [ 29] = "sami",
+ -- [ 30] = "faroese",
+ -- [ 31] = "farsi/persian",
+ -- [ 32] = "russian",
+ -- [ 33] = "chinese (simplified)",
+ -- [ 34] = "flemish",
+ -- [ 35] = "irish gaelic",
+ -- [ 36] = "albanian",
+ -- [ 37] = "romanian",
+ -- [ 38] = "czech",
+ -- [ 39] = "slovak",
+ -- [ 40] = "slovenian",
+ -- [ 41] = "yiddish",
+ -- [ 42] = "serbian",
+ -- [ 43] = "macedonian",
+ -- [ 44] = "bulgarian",
+ -- [ 45] = "ukrainian",
+ -- [ 46] = "byelorussian",
+ -- [ 47] = "uzbek",
+ -- [ 48] = "kazakh",
+ -- [ 49] = "azerbaijani (cyrillic script)",
+ -- [ 50] = "azerbaijani (arabic script)",
+ -- [ 51] = "armenian",
+ -- [ 52] = "georgian",
+ -- [ 53] = "moldavian",
+ -- [ 54] = "kirghiz",
+ -- [ 55] = "tajiki",
+ -- [ 56] = "turkmen",
+ -- [ 57] = "mongolian (mongolian script)",
+ -- [ 58] = "mongolian (cyrillic script)",
+ -- [ 59] = "pashto",
+ -- [ 60] = "kurdish",
+ -- [ 61] = "kashmiri",
+ -- [ 62] = "sindhi",
+ -- [ 63] = "tibetan",
+ -- [ 64] = "nepali",
+ -- [ 65] = "sanskrit",
+ -- [ 66] = "marathi",
+ -- [ 67] = "bengali",
+ -- [ 68] = "assamese",
+ -- [ 69] = "gujarati",
+ -- [ 70] = "punjabi",
+ -- [ 71] = "oriya",
+ -- [ 72] = "malayalam",
+ -- [ 73] = "kannada",
+ -- [ 74] = "tamil",
+ -- [ 75] = "telugu",
+ -- [ 76] = "sinhalese",
+ -- [ 77] = "burmese",
+ -- [ 78] = "khmer",
+ -- [ 79] = "lao",
+ -- [ 80] = "vietnamese",
+ -- [ 81] = "indonesian",
+ -- [ 82] = "tagalong",
+ -- [ 83] = "malay (roman script)",
+ -- [ 84] = "malay (arabic script)",
+ -- [ 85] = "amharic",
+ -- [ 86] = "tigrinya",
+ -- [ 87] = "galla",
+ -- [ 88] = "somali",
+ -- [ 89] = "swahili",
+ -- [ 90] = "kinyarwanda/ruanda",
+ -- [ 91] = "rundi",
+ -- [ 92] = "nyanja/chewa",
+ -- [ 93] = "malagasy",
+ -- [ 94] = "esperanto",
+ -- [128] = "welsh",
+ -- [129] = "basque",
+ -- [130] = "catalan",
+ -- [131] = "latin",
+ -- [132] = "quenchua",
+ -- [133] = "guarani",
+ -- [134] = "aymara",
+ -- [135] = "tatar",
+ -- [136] = "uighur",
+ -- [137] = "dzongkha",
+ -- [138] = "javanese (roman script)",
+ -- [139] = "sundanese (roman script)",
+ -- [140] = "galician",
+ -- [141] = "afrikaans",
+ -- [142] = "breton",
+ -- [143] = "inuktitut",
+ -- [144] = "scottish gaelic",
+ -- [145] = "manx gaelic",
+ -- [146] = "irish gaelic (with dot above)",
+ -- [147] = "tongan",
+ -- [148] = "greek (polytonic)",
+ -- [149] = "greenlandic",
+ -- [150] = "azerbaijani (roman script)",
},
-- these can stay:
iso = {
},
-- english can stay:
windows = {
- [0x0436] = "afrikaans - south africa",
- [0x041c] = "albanian - albania",
- [0x0484] = "alsatian - france",
- [0x045e] = "amharic - ethiopia",
- [0x1401] = "arabic - algeria",
- [0x3c01] = "arabic - bahrain",
- [0x0c01] = "arabic - egypt",
- [0x0801] = "arabic - iraq",
- [0x2c01] = "arabic - jordan",
- [0x3401] = "arabic - kuwait",
- [0x3001] = "arabic - lebanon",
- [0x1001] = "arabic - libya",
- [0x1801] = "arabic - morocco",
- [0x2001] = "arabic - oman",
- [0x4001] = "arabic - qatar",
- [0x0401] = "arabic - saudi arabia",
- [0x2801] = "arabic - syria",
- [0x1c01] = "arabic - tunisia",
- [0x3801] = "arabic - u.a.e.",
- [0x2401] = "arabic - yemen",
- [0x042b] = "armenian - armenia",
- [0x044d] = "assamese - india",
- [0x082c] = "azeri (cyrillic) - azerbaijan",
- [0x042c] = "azeri (latin) - azerbaijan",
- [0x046d] = "bashkir - russia",
- [0x042d] = "basque - basque",
- [0x0423] = "belarusian - belarus",
- [0x0845] = "bengali - bangladesh",
- [0x0445] = "bengali - india",
- [0x201a] = "bosnian (cyrillic) - bosnia and herzegovina",
- [0x141a] = "bosnian (latin) - bosnia and herzegovina",
- [0x047e] = "breton - france",
- [0x0402] = "bulgarian - bulgaria",
- [0x0403] = "catalan - catalan",
- [0x0c04] = "chinese - hong kong s.a.r.",
- [0x1404] = "chinese - macao s.a.r.",
- [0x0804] = "chinese - people's republic of china",
- [0x1004] = "chinese - singapore",
- [0x0404] = "chinese - taiwan",
- [0x0483] = "corsican - france",
- [0x041a] = "croatian - croatia",
- [0x101a] = "croatian (latin) - bosnia and herzegovina",
- [0x0405] = "czech - czech republic",
- [0x0406] = "danish - denmark",
- [0x048c] = "dari - afghanistan",
- [0x0465] = "divehi - maldives",
- [0x0813] = "dutch - belgium",
- [0x0413] = "dutch - netherlands",
- [0x0c09] = "english - australia",
- [0x2809] = "english - belize",
- [0x1009] = "english - canada",
- [0x2409] = "english - caribbean",
- [0x4009] = "english - india",
- [0x1809] = "english - ireland",
- [0x2009] = "english - jamaica",
- [0x4409] = "english - malaysia",
- [0x1409] = "english - new zealand",
- [0x3409] = "english - republic of the philippines",
- [0x4809] = "english - singapore",
- [0x1c09] = "english - south africa",
- [0x2c09] = "english - trinidad and tobago",
- [0x0809] = "english - united kingdom",
+ -- [0x0436] = "afrikaans - south africa",
+ -- [0x041c] = "albanian - albania",
+ -- [0x0484] = "alsatian - france",
+ -- [0x045e] = "amharic - ethiopia",
+ -- [0x1401] = "arabic - algeria",
+ -- [0x3c01] = "arabic - bahrain",
+ -- [0x0c01] = "arabic - egypt",
+ -- [0x0801] = "arabic - iraq",
+ -- [0x2c01] = "arabic - jordan",
+ -- [0x3401] = "arabic - kuwait",
+ -- [0x3001] = "arabic - lebanon",
+ -- [0x1001] = "arabic - libya",
+ -- [0x1801] = "arabic - morocco",
+ -- [0x2001] = "arabic - oman",
+ -- [0x4001] = "arabic - qatar",
+ -- [0x0401] = "arabic - saudi arabia",
+ -- [0x2801] = "arabic - syria",
+ -- [0x1c01] = "arabic - tunisia",
+ -- [0x3801] = "arabic - u.a.e.",
+ -- [0x2401] = "arabic - yemen",
+ -- [0x042b] = "armenian - armenia",
+ -- [0x044d] = "assamese - india",
+ -- [0x082c] = "azeri (cyrillic) - azerbaijan",
+ -- [0x042c] = "azeri (latin) - azerbaijan",
+ -- [0x046d] = "bashkir - russia",
+ -- [0x042d] = "basque - basque",
+ -- [0x0423] = "belarusian - belarus",
+ -- [0x0845] = "bengali - bangladesh",
+ -- [0x0445] = "bengali - india",
+ -- [0x201a] = "bosnian (cyrillic) - bosnia and herzegovina",
+ -- [0x141a] = "bosnian (latin) - bosnia and herzegovina",
+ -- [0x047e] = "breton - france",
+ -- [0x0402] = "bulgarian - bulgaria",
+ -- [0x0403] = "catalan - catalan",
+ -- [0x0c04] = "chinese - hong kong s.a.r.",
+ -- [0x1404] = "chinese - macao s.a.r.",
+ -- [0x0804] = "chinese - people's republic of china",
+ -- [0x1004] = "chinese - singapore",
+ -- [0x0404] = "chinese - taiwan",
+ -- [0x0483] = "corsican - france",
+ -- [0x041a] = "croatian - croatia",
+ -- [0x101a] = "croatian (latin) - bosnia and herzegovina",
+ -- [0x0405] = "czech - czech republic",
+ -- [0x0406] = "danish - denmark",
+ -- [0x048c] = "dari - afghanistan",
+ -- [0x0465] = "divehi - maldives",
+ -- [0x0813] = "dutch - belgium",
+ -- [0x0413] = "dutch - netherlands",
+ -- [0x0c09] = "english - australia",
+ -- [0x2809] = "english - belize",
+ -- [0x1009] = "english - canada",
+ -- [0x2409] = "english - caribbean",
+ -- [0x4009] = "english - india",
+ -- [0x1809] = "english - ireland",
+ -- [0x2009] = "english - jamaica",
+ -- [0x4409] = "english - malaysia",
+ -- [0x1409] = "english - new zealand",
+ -- [0x3409] = "english - republic of the philippines",
+ -- [0x4809] = "english - singapore",
+ -- [0x1c09] = "english - south africa",
+ -- [0x2c09] = "english - trinidad and tobago",
+ -- [0x0809] = "english - united kingdom",
[0x0409] = "english - united states",
- [0x3009] = "english - zimbabwe",
- [0x0425] = "estonian - estonia",
- [0x0438] = "faroese - faroe islands",
- [0x0464] = "filipino - philippines",
- [0x040b] = "finnish - finland",
- [0x080c] = "french - belgium",
- [0x0c0c] = "french - canada",
- [0x040c] = "french - france",
- [0x140c] = "french - luxembourg",
- [0x180c] = "french - principality of monoco",
- [0x100c] = "french - switzerland",
- [0x0462] = "frisian - netherlands",
- [0x0456] = "galician - galician",
- [0x0437] = "georgian -georgia",
- [0x0c07] = "german - austria",
- [0x0407] = "german - germany",
- [0x1407] = "german - liechtenstein",
- [0x1007] = "german - luxembourg",
- [0x0807] = "german - switzerland",
- [0x0408] = "greek - greece",
- [0x046f] = "greenlandic - greenland",
- [0x0447] = "gujarati - india",
- [0x0468] = "hausa (latin) - nigeria",
- [0x040d] = "hebrew - israel",
- [0x0439] = "hindi - india",
- [0x040e] = "hungarian - hungary",
- [0x040f] = "icelandic - iceland",
- [0x0470] = "igbo - nigeria",
- [0x0421] = "indonesian - indonesia",
- [0x045d] = "inuktitut - canada",
- [0x085d] = "inuktitut (latin) - canada",
- [0x083c] = "irish - ireland",
- [0x0434] = "isixhosa - south africa",
- [0x0435] = "isizulu - south africa",
- [0x0410] = "italian - italy",
- [0x0810] = "italian - switzerland",
- [0x0411] = "japanese - japan",
- [0x044b] = "kannada - india",
- [0x043f] = "kazakh - kazakhstan",
- [0x0453] = "khmer - cambodia",
- [0x0486] = "k'iche - guatemala",
- [0x0487] = "kinyarwanda - rwanda",
- [0x0441] = "kiswahili - kenya",
- [0x0457] = "konkani - india",
- [0x0412] = "korean - korea",
- [0x0440] = "kyrgyz - kyrgyzstan",
- [0x0454] = "lao - lao p.d.r.",
- [0x0426] = "latvian - latvia",
- [0x0427] = "lithuanian - lithuania",
- [0x082e] = "lower sorbian - germany",
- [0x046e] = "luxembourgish - luxembourg",
- [0x042f] = "macedonian (fyrom) - former yugoslav republic of macedonia",
- [0x083e] = "malay - brunei darussalam",
- [0x043e] = "malay - malaysia",
- [0x044c] = "malayalam - india",
- [0x043a] = "maltese - malta",
- [0x0481] = "maori - new zealand",
- [0x047a] = "mapudungun - chile",
- [0x044e] = "marathi - india",
- [0x047c] = "mohawk - mohawk",
- [0x0450] = "mongolian (cyrillic) - mongolia",
- [0x0850] = "mongolian (traditional) - people's republic of china",
- [0x0461] = "nepali - nepal",
- [0x0414] = "norwegian (bokmal) - norway",
- [0x0814] = "norwegian (nynorsk) - norway",
- [0x0482] = "occitan - france",
- [0x0448] = "odia (formerly oriya) - india",
- [0x0463] = "pashto - afghanistan",
- [0x0415] = "polish - poland",
- [0x0416] = "portuguese - brazil",
- [0x0816] = "portuguese - portugal",
- [0x0446] = "punjabi - india",
- [0x046b] = "quechua - bolivia",
- [0x086b] = "quechua - ecuador",
- [0x0c6b] = "quechua - peru",
- [0x0418] = "romanian - romania",
- [0x0417] = "romansh - switzerland",
- [0x0419] = "russian - russia",
- [0x243b] = "sami (inari) - finland",
- [0x103b] = "sami (lule) - norway",
- [0x143b] = "sami (lule) - sweden",
- [0x0c3b] = "sami (northern) - finland",
- [0x043b] = "sami (northern) - norway",
- [0x083b] = "sami (northern) - sweden",
- [0x203b] = "sami (skolt) - finland",
- [0x183b] = "sami (southern) - norway",
- [0x1c3b] = "sami (southern) - sweden",
- [0x044f] = "sanskrit - india",
- [0x1c1a] = "serbian (cyrillic) - bosnia and herzegovina",
- [0x0c1a] = "serbian (cyrillic) - serbia",
- [0x181a] = "serbian (latin) - bosnia and herzegovina",
- [0x081a] = "serbian (latin) - serbia",
- [0x046c] = "sesotho sa leboa - south africa",
- [0x0432] = "setswana - south africa",
- [0x045b] = "sinhala - sri lanka",
- [0x041b] = "slovak - slovakia",
- [0x0424] = "slovenian - slovenia",
- [0x2c0a] = "spanish - argentina",
- [0x400a] = "spanish - bolivia",
- [0x340a] = "spanish - chile",
- [0x240a] = "spanish - colombia",
- [0x140a] = "spanish - costa rica",
- [0x1c0a] = "spanish - dominican republic",
- [0x300a] = "spanish - ecuador",
- [0x440a] = "spanish - el salvador",
- [0x100a] = "spanish - guatemala",
- [0x480a] = "spanish - honduras",
- [0x080a] = "spanish - mexico",
- [0x4c0a] = "spanish - nicaragua",
- [0x180a] = "spanish - panama",
- [0x3c0a] = "spanish - paraguay",
- [0x280a] = "spanish - peru",
- [0x500a] = "spanish - puerto rico",
- [0x0c0a] = "spanish (modern sort) - spain",
- [0x040a] = "spanish (traditional sort) - spain",
- [0x540a] = "spanish - united states",
- [0x380a] = "spanish - uruguay",
- [0x200a] = "spanish - venezuela",
- [0x081d] = "sweden - finland",
- [0x041d] = "swedish - sweden",
- [0x045a] = "syriac - syria",
- [0x0428] = "tajik (cyrillic) - tajikistan",
- [0x085f] = "tamazight (latin) - algeria",
- [0x0449] = "tamil - india",
- [0x0444] = "tatar - russia",
- [0x044a] = "telugu - india",
- [0x041e] = "thai - thailand",
- [0x0451] = "tibetan - prc",
- [0x041f] = "turkish - turkey",
- [0x0442] = "turkmen - turkmenistan",
- [0x0480] = "uighur - prc",
- [0x0422] = "ukrainian - ukraine",
- [0x042e] = "upper sorbian - germany",
- [0x0420] = "urdu - islamic republic of pakistan",
- [0x0843] = "uzbek (cyrillic) - uzbekistan",
- [0x0443] = "uzbek (latin) - uzbekistan",
- [0x042a] = "vietnamese - vietnam",
- [0x0452] = "welsh - united kingdom",
- [0x0488] = "wolof - senegal",
- [0x0485] = "yakut - russia",
- [0x0478] = "yi - prc",
- [0x046a] = "yoruba - nigeria",
+ -- [0x3009] = "english - zimbabwe",
+ -- [0x0425] = "estonian - estonia",
+ -- [0x0438] = "faroese - faroe islands",
+ -- [0x0464] = "filipino - philippines",
+ -- [0x040b] = "finnish - finland",
+ -- [0x080c] = "french - belgium",
+ -- [0x0c0c] = "french - canada",
+ -- [0x040c] = "french - france",
+ -- [0x140c] = "french - luxembourg",
+ -- [0x180c] = "french - principality of monoco",
+ -- [0x100c] = "french - switzerland",
+ -- [0x0462] = "frisian - netherlands",
+ -- [0x0456] = "galician - galician",
+ -- [0x0437] = "georgian -georgia",
+ -- [0x0c07] = "german - austria",
+ -- [0x0407] = "german - germany",
+ -- [0x1407] = "german - liechtenstein",
+ -- [0x1007] = "german - luxembourg",
+ -- [0x0807] = "german - switzerland",
+ -- [0x0408] = "greek - greece",
+ -- [0x046f] = "greenlandic - greenland",
+ -- [0x0447] = "gujarati - india",
+ -- [0x0468] = "hausa (latin) - nigeria",
+ -- [0x040d] = "hebrew - israel",
+ -- [0x0439] = "hindi - india",
+ -- [0x040e] = "hungarian - hungary",
+ -- [0x040f] = "icelandic - iceland",
+ -- [0x0470] = "igbo - nigeria",
+ -- [0x0421] = "indonesian - indonesia",
+ -- [0x045d] = "inuktitut - canada",
+ -- [0x085d] = "inuktitut (latin) - canada",
+ -- [0x083c] = "irish - ireland",
+ -- [0x0434] = "isixhosa - south africa",
+ -- [0x0435] = "isizulu - south africa",
+ -- [0x0410] = "italian - italy",
+ -- [0x0810] = "italian - switzerland",
+ -- [0x0411] = "japanese - japan",
+ -- [0x044b] = "kannada - india",
+ -- [0x043f] = "kazakh - kazakhstan",
+ -- [0x0453] = "khmer - cambodia",
+ -- [0x0486] = "k'iche - guatemala",
+ -- [0x0487] = "kinyarwanda - rwanda",
+ -- [0x0441] = "kiswahili - kenya",
+ -- [0x0457] = "konkani - india",
+ -- [0x0412] = "korean - korea",
+ -- [0x0440] = "kyrgyz - kyrgyzstan",
+ -- [0x0454] = "lao - lao p.d.r.",
+ -- [0x0426] = "latvian - latvia",
+ -- [0x0427] = "lithuanian - lithuania",
+ -- [0x082e] = "lower sorbian - germany",
+ -- [0x046e] = "luxembourgish - luxembourg",
+ -- [0x042f] = "macedonian (fyrom) - former yugoslav republic of macedonia",
+ -- [0x083e] = "malay - brunei darussalam",
+ -- [0x043e] = "malay - malaysia",
+ -- [0x044c] = "malayalam - india",
+ -- [0x043a] = "maltese - malta",
+ -- [0x0481] = "maori - new zealand",
+ -- [0x047a] = "mapudungun - chile",
+ -- [0x044e] = "marathi - india",
+ -- [0x047c] = "mohawk - mohawk",
+ -- [0x0450] = "mongolian (cyrillic) - mongolia",
+ -- [0x0850] = "mongolian (traditional) - people's republic of china",
+ -- [0x0461] = "nepali - nepal",
+ -- [0x0414] = "norwegian (bokmal) - norway",
+ -- [0x0814] = "norwegian (nynorsk) - norway",
+ -- [0x0482] = "occitan - france",
+ -- [0x0448] = "odia (formerly oriya) - india",
+ -- [0x0463] = "pashto - afghanistan",
+ -- [0x0415] = "polish - poland",
+ -- [0x0416] = "portuguese - brazil",
+ -- [0x0816] = "portuguese - portugal",
+ -- [0x0446] = "punjabi - india",
+ -- [0x046b] = "quechua - bolivia",
+ -- [0x086b] = "quechua - ecuador",
+ -- [0x0c6b] = "quechua - peru",
+ -- [0x0418] = "romanian - romania",
+ -- [0x0417] = "romansh - switzerland",
+ -- [0x0419] = "russian - russia",
+ -- [0x243b] = "sami (inari) - finland",
+ -- [0x103b] = "sami (lule) - norway",
+ -- [0x143b] = "sami (lule) - sweden",
+ -- [0x0c3b] = "sami (northern) - finland",
+ -- [0x043b] = "sami (northern) - norway",
+ -- [0x083b] = "sami (northern) - sweden",
+ -- [0x203b] = "sami (skolt) - finland",
+ -- [0x183b] = "sami (southern) - norway",
+ -- [0x1c3b] = "sami (southern) - sweden",
+ -- [0x044f] = "sanskrit - india",
+ -- [0x1c1a] = "serbian (cyrillic) - bosnia and herzegovina",
+ -- [0x0c1a] = "serbian (cyrillic) - serbia",
+ -- [0x181a] = "serbian (latin) - bosnia and herzegovina",
+ -- [0x081a] = "serbian (latin) - serbia",
+ -- [0x046c] = "sesotho sa leboa - south africa",
+ -- [0x0432] = "setswana - south africa",
+ -- [0x045b] = "sinhala - sri lanka",
+ -- [0x041b] = "slovak - slovakia",
+ -- [0x0424] = "slovenian - slovenia",
+ -- [0x2c0a] = "spanish - argentina",
+ -- [0x400a] = "spanish - bolivia",
+ -- [0x340a] = "spanish - chile",
+ -- [0x240a] = "spanish - colombia",
+ -- [0x140a] = "spanish - costa rica",
+ -- [0x1c0a] = "spanish - dominican republic",
+ -- [0x300a] = "spanish - ecuador",
+ -- [0x440a] = "spanish - el salvador",
+ -- [0x100a] = "spanish - guatemala",
+ -- [0x480a] = "spanish - honduras",
+ -- [0x080a] = "spanish - mexico",
+ -- [0x4c0a] = "spanish - nicaragua",
+ -- [0x180a] = "spanish - panama",
+ -- [0x3c0a] = "spanish - paraguay",
+ -- [0x280a] = "spanish - peru",
+ -- [0x500a] = "spanish - puerto rico",
+ -- [0x0c0a] = "spanish (modern sort) - spain",
+ -- [0x040a] = "spanish (traditional sort) - spain",
+ -- [0x540a] = "spanish - united states",
+ -- [0x380a] = "spanish - uruguay",
+ -- [0x200a] = "spanish - venezuela",
+ -- [0x081d] = "sweden - finland",
+ -- [0x041d] = "swedish - sweden",
+ -- [0x045a] = "syriac - syria",
+ -- [0x0428] = "tajik (cyrillic) - tajikistan",
+ -- [0x085f] = "tamazight (latin) - algeria",
+ -- [0x0449] = "tamil - india",
+ -- [0x0444] = "tatar - russia",
+ -- [0x044a] = "telugu - india",
+ -- [0x041e] = "thai - thailand",
+ -- [0x0451] = "tibetan - prc",
+ -- [0x041f] = "turkish - turkey",
+ -- [0x0442] = "turkmen - turkmenistan",
+ -- [0x0480] = "uighur - prc",
+ -- [0x0422] = "ukrainian - ukraine",
+ -- [0x042e] = "upper sorbian - germany",
+ -- [0x0420] = "urdu - islamic republic of pakistan",
+ -- [0x0843] = "uzbek (cyrillic) - uzbekistan",
+ -- [0x0443] = "uzbek (latin) - uzbekistan",
+ -- [0x042a] = "vietnamese - vietnam",
+ -- [0x0452] = "welsh - united kingdom",
+ -- [0x0488] = "wolof - senegal",
+ -- [0x0485] = "yakut - russia",
+ -- [0x0478] = "yi - prc",
+ -- [0x046a] = "yoruba - nigeria",
},
custom = {
},
@@ -1129,6 +1129,7 @@ formatreaders[4] = function(f,fontdata,offset)
local indices = { }
local mapping = fontdata.mapping
local glyphs = fontdata.glyphs
+ local duplicates = fontdata.duplicates
--
for i=1,nofsegments do
endchars[i] = readushort(f)
@@ -1162,10 +1163,15 @@ formatreaders[4] = function(f,fontdata,offset)
if index and index > 0 then
local glyph = glyphs[index]
if glyph then
- if not glyph.unicode then
+ local gu = glyph.unicode
+ if not gu then
glyph.unicode = unicode
+ else
+ -- no duplicates ... weird side effects in lm
+ end
+ if not mapping[index] then
+ mapping[index] = unicode
end
- mapping[index] = unicode
-- report("case 1: %C %04i %s",unicode,index,glyphs[index].name)
end
end
@@ -1179,10 +1185,15 @@ formatreaders[4] = function(f,fontdata,offset)
index = mod(index + delta,65536)
local glyph = glyphs[index]
if glyph then
- if not glyph.unicode then
+ local gu = glyph.unicode
+ if not gu then
glyph.unicode = unicode
+ else
+ -- no duplicates ... weird side effects in lm
+ end
+ if not mapping[index] then
+ mapping[index] = unicode
end
- mapping[index] = unicode
-- report("case 2: %C %04i %s",unicode,index,glyphs[index].name)
end
end
@@ -1194,37 +1205,59 @@ end
formatreaders[6] = function(f,fontdata,offset)
setposition(f,offset+2+2+2) -- skip format length language
- local mapping = fontdata.mapping
- local glyphs = fontdata.glyphs
- local start = readushort(f)
- local count = readushort(f)
+ local mapping = fontdata.mapping
+ local glyphs = fontdata.glyphs
+ local duplicates = fontdata.duplicates
+ local start = readushort(f)
+ local count = readushort(f)
for unicode=start,start+count-1 do
local index = readushort(f)
if index > 0 then
local glyph = glyphs[index]
- if not glyph.unicode then
- glyph.unicode = unicode
+ if glyph then
+ local gu = glyph.unicode
+ if not gu then
+ glyph.unicode = unicode
+ else
+ -- no duplicates ... weird side effects in lm
+ end
+ if not mapping[index] then
+ mapping[index] = unicode
+ end
end
- mapping[index] = unicode
end
end
end
formatreaders[12] = function(f,fontdata,offset)
setposition(f,offset+2+2+4+4) -- skip format reserved length language
- local mapping = fontdata.mapping
- local glyphs = fontdata.glyphs
- local nofgroups = readulong(f)
+ local mapping = fontdata.mapping
+ local glyphs = fontdata.glyphs
+ local duplicates = fontdata.duplicates
+ local nofgroups = readulong(f)
for i=1,nofgroups do
local first = readulong(f)
local last = readulong(f)
local index = readulong(f)
for unicode=first,last do
local glyph = glyphs[index]
- if not glyph.unicode then
- glyph.unicode = unicode
+ if glyph then
+ local gu = glyph.unicode
+ if not gu then
+ glyph.unicode = unicode
+ elseif gu ~= unicode then
+ -- e.g. sourcehan fonts need this
+ local d = duplicates[gu]
+ if d then
+ d[unicode] = true
+ else
+ duplicates[gu] = { [unicode] = true }
+ end
+ end
+ if not mapping[index] then
+ mapping[index] = unicode
+ end
end
- mapping[index] = unicode
index = index + 1
end
end
@@ -1307,12 +1340,14 @@ function readers.cmap(f,fontdata,specification)
if datatable then
local tableoffset = datatable.offset
setposition(f,tableoffset)
- local version = readushort(f)
- local noftables = readushort(f)
- local records = { }
- local unicodecid = false
- local variantcid = false
- local variants = { }
+ local version = readushort(f)
+ local noftables = readushort(f)
+ local records = { }
+ local unicodecid = false
+ local variantcid = false
+ local variants = { }
+ local duplicates = fontdata.duplicates or { }
+ fontdata.duplicates = duplicates
for i=1,noftables do
local platform = readushort(f)
local encoding = readushort(f)
@@ -1371,7 +1406,7 @@ function readers.cmap(f,fontdata,specification)
table.sort(list)
report("no unicode cmap record loaded, found tables: % t",list)
end
- checkcmap(f,fontdata,records,0, 5,14) -- variants
+ checkcmap(f,fontdata,records,0,5,14) -- variants
--
fontdata.cidmaps = {
version = version,
@@ -1901,7 +1936,7 @@ function readers.loadfont(filename,n)
resources = {
filename = fontdata.filename,
private = privateoffset,
- duplicates = { }, -- todo
+ duplicates = fontdata.duplicates or { },
features = fontdata.features or { }, -- we need to add these in the loader
sublookups = fontdata.sublookups or { }, -- we need to add these in the loader
marks = fontdata.marks or { }, -- we need to add these in the loader