[arabic-fallback] Generate PUA table from data

Uses packtab for more compact arrays.
pull/3670/head
Khaled Hosny 2 years ago committed by Behdad Esfahbod
parent abc0685749
commit a15ad778fe
  1. 0
      src/ArabicPUASimplified.txt
  2. 0
      src/ArabicPUATraditional.txt
  3. 35
      src/gen-arabic-pua.py
  4. 6
      src/hb-ot-cmap-table.hh
  5. 383
      src/hb-ot-shaper-arabic-pua.hh

@ -0,0 +1,35 @@
#!/usr/bin/env python3
"""usage: ./gen-arabic-pua.py
"""
import packTab
print ("/* == Start of generated table == */")
print ("/*")
print (" * The following table is generated by running:")
print (" *")
print (" * ./gen-arabic-pua.py")
print (" *")
print (" */")
print ()
print ("#ifndef HB_OT_SHAPER_ARABIC_PUA_HH")
print ("#define HB_OT_SHAPER_ARABIC_PUA_HH")
print ()
code = packTab.Code('_hb_arabic')
for p in ("ArabicPUASimplified.txt", "ArabicPUATraditional.txt"):
with open (p, encoding='utf-8') as f:
fields = [l.split('\t') for l in f if l[:1] != '#']
data = {int(fs[1], 16):int(fs[0], 16) for fs in fields}
sol = packTab.pack_table(data, compression=9)
sol.genCode(code, f'pua_{p[9:13].lower()}_map')
code.print_c(linkage='static inline')
print ()
print ("#endif /* HB_OT_SHAPER_ARABIC_PUA_HH */")
print ()
print ("/* == End of generated table == */")

@ -1504,8 +1504,8 @@ struct SubtableUnicodesCache {
};
static inline hb_codepoint_t
_hb_symbol_pua_map (hb_codepoint_t codepoint)
static inline uint_fast16_t
_hb_symbol_pua_map (unsigned codepoint)
{
if (codepoint <= 0x00FFu)
{
@ -1841,7 +1841,7 @@ struct cmap
typedef bool (*hb_cmap_get_glyph_func_t) (const void *obj,
hb_codepoint_t codepoint,
hb_codepoint_t *glyph);
typedef hb_codepoint_t (*hb_pua_remap_func_t) (hb_codepoint_t);
typedef uint_fast16_t (*hb_pua_remap_func_t) (unsigned);
template <typename Type>
HB_INTERNAL static bool get_glyph_from (const void *obj,

@ -1,289 +1,118 @@
/* == Start of generated table == */
/*
* The following table is generated by running:
*
* ./gen-arabic-pua.py
*
*/
#ifndef HB_OT_SHAPER_ARABIC_PUA_HH
#define HB_OT_SHAPER_ARABIC_PUA_HH
static const uint16_t _arabic_table_pua_simp[][128] = {
{ /* 0x0000u..0x007Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF120u, 0xF121u, 0xF122u, 0x0000u, 0x0000u, 0xF125u, 0x0000u, 0x0000u,
0xF128u, 0xF129u, 0xF12Au, 0xF12Bu, 0xF15Eu, 0xF12Du, 0xF12Eu, 0xF12Fu,
0xF1B0u, 0xF1B1u, 0xF1B2u, 0xF1B3u, 0xF1B4u, 0xF1B5u, 0xF1B6u, 0xF1B7u,
0xF1B8u, 0xF1B9u, 0xF13Au, 0xF13Bu, 0x0000u, 0xF13Du, 0x0000u, 0xF13Fu,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF15Bu, 0xF15Cu, 0xF15Du, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x0080u..0x00FFu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF123u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF124u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF126u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF127u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x0600u..0x067Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF12Cu, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF13Bu, 0x0000u, 0x0000u, 0x0000u, 0xF13Fu,
0x0000u, 0xF1ADu, 0xF145u, 0xF143u, 0xF1BBu, 0xF147u, 0xF1BAu, 0xF141u,
0xF14Au, 0xF1A9u, 0xF14Cu, 0xF14Eu, 0xF151u, 0xF154u, 0xF157u, 0xF158u,
0xF159u, 0xF15Au, 0xF160u, 0xF162u, 0xF164u, 0xF166u, 0xF168u, 0xF169u,
0xF16Au, 0xF16Eu, 0xF172u, 0xF100u, 0xF100u, 0xF100u, 0xF100u, 0xF100u,
0xF15Fu, 0xF175u, 0xF178u, 0xF17Au, 0xF17Cu, 0xF17Eu, 0xF1E1u, 0xF1A4u,
0xF1A5u, 0xF1ACu, 0xF1A8u, 0xF1C7u, 0xF1C8u, 0xF1CBu, 0xF1C4u, 0xF1C5u,
0xF1CAu, 0xF1C9u, 0xF1C6u, 0xF100u, 0xF100u, 0xF100u, 0xF100u, 0xF100u,
0xF100u, 0xF100u, 0xF100u, 0xF100u, 0xF100u, 0xF100u, 0xF100u, 0x0000u,
0xF130u, 0xF131u, 0xF132u, 0xF133u, 0xF134u, 0xF135u, 0xF136u, 0xF137u,
0xF138u, 0xF139u, 0x0000u, 0xF15Eu, 0xF15Eu, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x2000u..0x207Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF10Cu, 0xF10Du, 0xF10Eu, 0xF10Fu,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF13Cu, 0xF13Eu, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0xFE80u..0xFEFFu */
0x0000u, 0xF145u, 0xF146u, 0xF143u, 0xF144u, 0xF1BBu, 0xF1BBu, 0xF147u,
0xF148u, 0xF1BAu, 0xF1AFu, 0xF1AEu, 0xF1AEu, 0xF141u, 0xF142u, 0xF14Au,
0xF14Au, 0xF149u, 0xF149u, 0xF1A9u, 0xF1AAu, 0xF14Cu, 0xF14Cu, 0xF14Bu,
0xF14Bu, 0xF14Eu, 0xF14Eu, 0xF14Du, 0xF14Du, 0xF151u, 0xF150u, 0xF14Fu,
0xF14Fu, 0xF154u, 0xF153u, 0xF152u, 0xF152u, 0xF157u, 0xF156u, 0xF155u,
0xF155u, 0xF158u, 0xF158u, 0xF159u, 0xF159u, 0xF15Au, 0xF15Au, 0xF160u,
0xF160u, 0xF162u, 0xF162u, 0xF161u, 0xF161u, 0xF164u, 0xF164u, 0xF163u,
0xF163u, 0xF166u, 0xF166u, 0xF165u, 0xF165u, 0xF168u, 0xF168u, 0xF167u,
0xF167u, 0xF169u, 0xF169u, 0xF169u, 0xF169u, 0xF16Au, 0xF16Au, 0xF16Au,
0xF16Au, 0xF16Eu, 0xF16Du, 0xF16Bu, 0xF16Cu, 0xF172u, 0xF171u, 0xF16Fu,
0xF170u, 0xF175u, 0xF175u, 0xF173u, 0xF174u, 0xF178u, 0xF178u, 0xF176u,
0xF177u, 0xF17Au, 0xF17Au, 0xF179u, 0xF179u, 0xF17Cu, 0xF17Cu, 0xF17Bu,
0xF17Bu, 0xF17Eu, 0xF17Eu, 0xF17Du, 0xF17Du, 0xF1E1u, 0xF1E1u, 0xF17Fu,
0xF17Fu, 0xF1A4u, 0xF1A3u, 0xF1A1u, 0xF1A2u, 0xF1A5u, 0xF1A5u, 0xF1ACu,
0xF1ABu, 0xF1A8u, 0xF1A7u, 0xF1A6u, 0xF1A6u, 0xF1C0u, 0xF1C1u, 0xF1BEu,
0xF1BFu, 0xF1C2u, 0xF1C3u, 0xF1BDu, 0xF1BCu, 0x0000u, 0x0000u, 0x0000u,
},
static const uint8_t
_hb_arabic_u8[464] =
{
84, 86, 85, 85, 85, 85, 85,213, 16, 34, 34, 34, 34, 34, 35, 34,
34, 34, 34, 34, 34, 34, 34, 34, 36, 34, 34, 34, 34, 34, 34, 34,
34, 34, 34, 34, 34, 34, 82, 16, 0, 0, 0, 0, 1, 2, 3, 4,
0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7,
0, 0, 8, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 12, 13, 14, 15,
16, 17, 18, 19, 20, 21, 0, 0, 0, 22, 0, 23, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 24, 25, 26, 27, 28, 29, 30, 31,
32, 33, 34, 35, 36, 37, 38, 39, 16, 34, 34, 34, 35, 34, 34, 34,
34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34,
34, 34, 34, 34, 34, 34, 34, 66, 16, 50, 68, 68, 68, 68, 68, 68,
68, 68, 68, 68,101, 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, 68,
71, 68, 68, 68, 68, 68, 68, 68,152,186, 76, 77, 68,254, 16, 50,
0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 0, 0, 5, 6,
0, 0, 0, 0, 0, 0, 7, 8, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 10, 0,
0, 0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 13, 0, 0, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
24, 25, 26, 27, 28, 23, 23, 29, 30, 31, 32, 33, 0, 0, 0, 0,
0, 0, 0, 34, 0, 0, 0, 35, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 36, 37, 38, 0, 0, 0, 0, 0, 0, 0, 39, 0, 0, 40,
41, 42, 0, 43, 44, 0, 0, 45, 46, 0, 47, 48, 49, 0, 0, 0,
0, 50, 0, 0, 51, 52, 0, 53, 54, 55, 56, 57, 58, 0, 0, 0,
0, 0, 59, 60, 61, 62, 63, 64, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 0, 0, 66,
0, 0, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
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,
};
static inline hb_codepoint_t
_hb_arabic_pua_simp_map (hb_codepoint_t codepoint)
static const uint16_t
_hb_arabic_u16[720] =
{
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0000u, 0x007Fu)) return _arabic_table_pua_simp[0][codepoint];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0080u, 0x00FFu)) return _arabic_table_pua_simp[1][codepoint - 0x0080u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0600u, 0x067Fu)) return _arabic_table_pua_simp[2][codepoint - 0x0600u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x2000u, 0x207Fu)) return _arabic_table_pua_simp[3][codepoint - 0x2000u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFE80u, 0xFEFFu)) return _arabic_table_pua_simp[4][codepoint - 0xFE80u];
return 0;
}
static const uint16_t _arabic_table_pua_trad[][128] = {
{ /* 0x0000u..0x007Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF220u, 0xF221u, 0xF222u, 0x0000u, 0x0000u, 0xF225u, 0x0000u, 0x0000u,
0xF228u, 0xF229u, 0xF22Au, 0xF22Bu, 0xF25Eu, 0xF22Du, 0xF22Eu, 0xF22Fu,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0xF23Au, 0xF23Bu, 0x0000u, 0xF23Du, 0x0000u, 0xF23Fu,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF25Bu, 0x0000u, 0xF25Du, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x0080u..0x00FFu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF223u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF224u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF226u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF227u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x0600u..0x067Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF22Cu, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0xF23Bu, 0x0000u, 0x0000u, 0x0000u, 0xF23Fu,
0x0000u, 0xF2D5u, 0xF245u, 0xF243u, 0xF2DAu, 0xF247u, 0xF2D9u, 0xF241u,
0xF24Cu, 0xF2D1u, 0xF250u, 0xF254u, 0xF258u, 0xF260u, 0xF264u, 0xF265u,
0xF267u, 0xF269u, 0xF26Bu, 0xF270u, 0xF274u, 0xF278u, 0xF27Eu, 0xF2A2u,
0xF2A3u, 0xF2AAu, 0xF2AEu, 0xF200u, 0xF200u, 0xF200u, 0xF200u, 0xF200u,
0xF25Fu, 0xF2B2u, 0xF2B6u, 0xF2BAu, 0xF2BEu, 0xF2C2u, 0xF2C6u, 0xF2CAu,
0xF2CBu, 0xF2D4u, 0xF2D0u, 0xF2E7u, 0xF2E8u, 0xF2EBu, 0xF2E4u, 0xF2E5u,
0xF2EAu, 0xF2E9u, 0xF2E6u, 0xF200u, 0xF200u, 0xF200u, 0xF200u, 0xF200u,
0xF200u, 0xF200u, 0xF200u, 0xF200u, 0xF200u, 0xF200u, 0xF200u, 0x0000u,
0xF230u, 0xF231u, 0xF232u, 0xF233u, 0xF234u, 0xF235u, 0xF236u, 0xF237u,
0xF238u, 0xF239u, 0x0000u, 0xF25Eu, 0xF25Eu, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0x2000u..0x207Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF20Cu, 0xF20Du, 0xF20Eu, 0xF20Fu,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF23Cu, 0xF23Eu, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0xFBD0u..0xFC4Fu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF202u, 0x0000u, 0xF21Du, 0x0000u, 0x0000u, 0x0000u, 0xF203u, 0x0000u,
0xF21Eu, 0x0000u, 0xF204u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0xF29Fu, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF212u,
0xF213u, 0xF214u, 0xF205u, 0x0000u, 0xF21Cu, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF206u, 0x0000u,
},
{ /* 0xFC50u..0xFCCFu */
0xF21Fu, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF2EFu, 0x0000u,
0xF2ECu, 0xF2EDu, 0xF2F0u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0xF215u, 0x0000u, 0x0000u, 0xF292u, 0x0000u, 0x0000u,
0xF216u, 0x0000u, 0x0000u, 0xF293u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF295u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0xF217u, 0x0000u, 0x0000u, 0xF294u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF280u, 0xF281u, 0xF282u, 0xF296u,
0x0000u, 0xF283u, 0xF284u, 0xF285u, 0xF297u, 0x0000u, 0x0000u, 0x0000u,
0xF29Au, 0x0000u, 0xF29Bu, 0x0000u, 0xF29Cu, 0x0000u, 0x0000u, 0x0000u,
0xF218u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0xF286u, 0xF287u, 0xF288u, 0xF29Du, 0xF21Au, 0xF289u, 0xF28Au,
},
{ /* 0xFCD0u..0xFD4Fu */
0xF28Bu, 0xF29Eu, 0xF28Du, 0xF28Eu, 0x0000u, 0xF298u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0xF28Fu, 0xF290u, 0xF291u, 0xF299u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF219u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0xF27Bu, 0xF27Du,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0xFD50u..0xFDCFu */
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0xF210u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u, 0x0000u,
},
{ /* 0xFE80u..0xFEFFu */
0x0000u, 0xF245u, 0xF246u, 0xF243u, 0xF244u, 0xF2DAu, 0xF2DBu, 0xF247u,
0xF248u, 0xF2D9u, 0xF2D8u, 0xF2D6u, 0xF2D7u, 0xF241u, 0xF242u, 0xF24Cu,
0xF24Bu, 0xF249u, 0xF24Au, 0xF2D1u, 0xF2D2u, 0xF250u, 0xF24Fu, 0xF24Du,
0xF24Eu, 0xF254u, 0xF253u, 0xF251u, 0xF252u, 0xF258u, 0xF257u, 0xF255u,
0xF256u, 0xF260u, 0xF25Cu, 0xF259u, 0xF25Au, 0xF264u, 0xF263u, 0xF261u,
0xF262u, 0xF265u, 0xF266u, 0xF267u, 0xF268u, 0xF269u, 0xF26Au, 0xF26Bu,
0xF26Cu, 0xF270u, 0xF26Fu, 0xF26Du, 0xF26Eu, 0xF274u, 0xF273u, 0xF271u,
0xF272u, 0xF278u, 0xF277u, 0xF275u, 0xF276u, 0xF27Eu, 0xF27Cu, 0xF279u,
0xF27Au, 0xF2A2u, 0xF2A1u, 0xF27Fu, 0xF2F1u, 0xF2A6u, 0xF2A5u, 0xF2A3u,
0xF2A4u, 0xF2AAu, 0xF2A9u, 0xF2A7u, 0xF2A8u, 0xF2AEu, 0xF2ADu, 0xF2ABu,
0xF2ACu, 0xF2B2u, 0xF2B1u, 0xF2AFu, 0xF2B0u, 0xF2B6u, 0xF2B5u, 0xF2B3u,
0xF2B4u, 0xF2BAu, 0xF2B9u, 0xF2B7u, 0xF2B8u, 0xF2BEu, 0xF2BDu, 0xF2BBu,
0xF2BCu, 0xF2C2u, 0xF2C1u, 0xF2BFu, 0xF2C0u, 0xF2C6u, 0xF2C5u, 0xF2C3u,
0xF2C4u, 0xF2CAu, 0xF2C9u, 0xF2C7u, 0xF2C8u, 0xF2CBu, 0xF2CCu, 0xF2D4u,
0xF2D3u, 0xF2D0u, 0xF2CFu, 0xF2CDu, 0xF2CEu, 0xF2E0u, 0xF2E1u, 0xF2DEu,
0xF2DFu, 0xF2E2u, 0xF2E3u, 0xF2DCu, 0xF2DDu, 0x0000u, 0x0000u, 0x0000u,
},
0, 0, 0, 0, 0, 0, 0, 0,61728,61729,61730, 0, 0,61733, 0, 0,
61736,61737,61738,61739,61790,61741,61742,61743,61872,61873,61874,61875,61876,61877,61878,61879,
61880,61881,61754,61755, 0,61757, 0,61759, 0, 0, 0,61787,61788,61789, 0, 0,
0, 0, 0,61731, 0, 0, 0, 0, 0, 0, 0,61732, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0,61734, 0, 0, 0, 0, 0, 0, 0,61735,
0, 0, 0, 0,61740, 0, 0, 0, 0, 0, 0,61755, 0, 0, 0,61759,
0,61869,61765,61763,61883,61767,61882,61761,61770,61865,61772,61774,61777,61780,61783,61784,
61785,61786,61792,61794,61796,61798,61800,61801,61802,61806,61810,61696,61696,61696,61696,61696,
61791,61813,61816,61818,61820,61822,61921,61860,61861,61868,61864,61895,61896,61899,61892,61893,
61898,61897,61894,61696,61696,61696,61696,61696,61696,61696,61696,61696,61696,61696,61696, 0,
61744,61745,61746,61747,61748,61749,61750,61751,61752,61753, 0,61790,61790, 0, 0, 0,
0, 0, 0, 0,61708,61709,61710,61711,61756,61758, 0, 0, 0, 0, 0, 0,
0,61765,61766,61763,61764,61883,61883,61767,61768,61882,61871,61870,61870,61761,61762,61770,
61770,61769,61769,61865,61866,61772,61772,61771,61771,61774,61774,61773,61773,61777,61776,61775,
61775,61780,61779,61778,61778,61783,61782,61781,61781,61784,61784,61785,61785,61786,61786,61792,
61792,61794,61794,61793,61793,61796,61796,61795,61795,61798,61798,61797,61797,61800,61800,61799,
61799,61801,61801,61801,61801,61802,61802,61802,61802,61806,61805,61803,61804,61810,61809,61807,
61808,61813,61813,61811,61812,61816,61816,61814,61815,61818,61818,61817,61817,61820,61820,61819,
61819,61822,61822,61821,61821,61921,61921,61823,61823,61860,61859,61857,61858,61861,61861,61868,
61867,61864,61863,61862,61862,61888,61889,61886,61887,61890,61891,61885,61884, 0, 0, 0,
0, 0, 0, 0,61984,61985,61986, 0, 0,61989, 0, 0,61992,61993,61994,61995,
62046,61997,61998,61999, 0, 0,62010,62011, 0,62013, 0,62015, 0, 0, 0,62043,
0,62045, 0, 0, 0, 0, 0,61987, 0, 0, 0,61988, 0, 0, 0,61990,
0, 0, 0,61991,61996, 0, 0, 0, 0, 0, 0,62011, 0, 0, 0,62015,
0,62165,62021,62019,62170,62023,62169,62017,62028,62161,62032,62036,62040,62048,62052,62053,
62055,62057,62059,62064,62068,62072,62078,62114,62115,62122,62126,61952,61952,61952,61952,61952,
62047,62130,62134,62138,62142,62146,62150,62154,62155,62164,62160,62183,62184,62187,62180,62181,
62186,62185,62182,61952,61952,61952,61952, 0,62000,62001,62002,62003,62004,62005,62006,62007,
62008,62009, 0,62046,62046, 0, 0, 0,61964,61965,61966,61967,62012,62014, 0, 0,
61954, 0,61981, 0, 0, 0,61955, 0,61982, 0,61956, 0, 0, 0,62111, 0,
0, 0, 0,61970,61971,61972,61957, 0,61980, 0, 0, 0, 0, 0,61958, 0,
61983, 0, 0, 0, 0, 0,62191, 0,62188,62189,62192, 0, 0, 0,61973, 0,
0,62098, 0, 0,61974, 0, 0,62099, 0, 0,62101, 0, 0,61975, 0, 0,
62100, 0, 0, 0,62080,62081,62082,62102, 0,62083,62084,62085,62103, 0, 0, 0,
62106, 0,62107, 0,62108, 0, 0, 0,61976, 0, 0, 0, 0,62086,62087,62088,
62109,61978,62089,62090,62091,62110,62093,62094, 0,62104, 0, 0, 0, 0,62095,62096,
62097,62105, 0, 0,61977, 0, 0, 0, 0, 0,62075,62077,61968, 0, 0, 0,
0,62021,62022,62019,62020,62170,62171,62023,62024,62169,62168,62166,62167,62017,62018,62028,
62027,62025,62026,62161,62162,62032,62031,62029,62030,62036,62035,62033,62034,62040,62039,62037,
62038,62048,62044,62041,62042,62052,62051,62049,62050,62053,62054,62055,62056,62057,62058,62059,
62060,62064,62063,62061,62062,62068,62067,62065,62066,62072,62071,62069,62070,62078,62076,62073,
62074,62114,62113,62079,62193,62118,62117,62115,62116,62122,62121,62119,62120,62126,62125,62123,
62124,62130,62129,62127,62128,62134,62133,62131,62132,62138,62137,62135,62136,62142,62141,62139,
62140,62146,62145,62143,62144,62150,62149,62147,62148,62154,62153,62151,62152,62155,62156,62164,
62163,62160,62159,62157,62158,62176,62177,62174,62175,62178,62179,62172,62173, 0, 0, 0,
};
static inline hb_codepoint_t
_hb_arabic_pua_trad_map (hb_codepoint_t codepoint)
static inline unsigned
_hb_arabic_b2 (const uint8_t* a, unsigned i)
{
return (a[i>>2]>>((i&3u)<<1))&3u;
}
static inline unsigned
_hb_arabic_b4 (const uint8_t* a, unsigned i)
{
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0000u, 0x007Fu)) return _arabic_table_pua_trad[0][codepoint];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0080u, 0x00FFu)) return _arabic_table_pua_trad[1][codepoint - 0x0080u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x0600u, 0x067Fu)) return _arabic_table_pua_trad[2][codepoint - 0x0600u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0x2000u, 0x207Fu)) return _arabic_table_pua_trad[3][codepoint - 0x2000u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFBD0u, 0xFC4Fu)) return _arabic_table_pua_trad[4][codepoint - 0xFBD0u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFC50u, 0xFCCFu)) return _arabic_table_pua_trad[5][codepoint - 0xFC50u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFCD0u, 0xFD4Fu)) return _arabic_table_pua_trad[6][codepoint - 0xFCD0u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFD50u, 0xFDCFu)) return _arabic_table_pua_trad[7][codepoint - 0xFD50u];
if (hb_in_range<hb_codepoint_t> (codepoint, 0xFE80u, 0xFEFFu)) return _arabic_table_pua_trad[8][codepoint - 0xFE80u];
return 0;
return (a[i>>1]>>((i&1u)<<2))&15u;
}
static inline uint_fast16_t
_hb_arabic_pua_simp_map (unsigned u)
{
return u<65277u?_hb_arabic_u16[((_hb_arabic_u8[40+(((_hb_arabic_b4(8+_hb_arabic_u8,((_hb_arabic_b2(_hb_arabic_u8,u>>3>>4>>4))<<4)+((u>>3>>4)&15u)))<<4)+((u>>3)&15u))])<<3)+((u)&7u)]:0;
}
static inline uint_fast16_t
_hb_arabic_pua_trad_map (unsigned u)
{
return u<65277u?_hb_arabic_u16[320+(((_hb_arabic_u8[208+(((_hb_arabic_b4(168+_hb_arabic_u8,((_hb_arabic_b4(136+_hb_arabic_u8,u>>2>>4>>4))<<4)+((u>>2>>4)&15u)))<<4)+((u>>2)&15u))])<<2)+((u)&3u))]:0;
}
#endif /* HB_OT_SHAPER_ARABIC_PUA_HH */
/* == End of generated table == */

Loading…
Cancel
Save