[USE] Add CGJ to table
diff --git a/src/gen-use-table.py b/src/gen-use-table.py index 7293b73..8210875 100755 --- a/src/gen-use-table.py +++ b/src/gen-use-table.py
@@ -39,8 +39,12 @@ data[i][u] = t values[i][t] = values[i].get (t, 0) + end - start + 1 -# Merge data into one dict: defaults = ('Other', 'Not_Applicable', 'Cn', 'No_Block') + +# TODO CGJ is not in Unicode Indic files, but used in USE +data[0][0x034F] = defaults[0] + +# Merge data into one dict: for i,v in enumerate (defaults): values[i][v] = values[i].get (v, 0) + 1 combined = {} @@ -180,7 +184,10 @@ return U == 0x2060 def is_OTHER(U, UISC, UGC): #SPEC-OUTDATED return UGC == Zs # or any other SCRIPT_COMMON characters - return UISC == Other and not is_SYM_MOD(U, UISC, UGC) + return (UISC == Other + and not is_SYM_MOD(U, UISC, UGC) + and not is_CGJ(U, UISC, UGC) + ) def is_Reserved(U, UISC, UGC): return UGC == 'Cn' def is_REPHA(U, UISC, UGC): @@ -325,7 +332,7 @@ # Remove the outliers singles = {} -for u in [0x25CC, 0x1107F]: +for u in [0x034F, 0x25CC, 0x1107F]: singles[u] = data[u] del data[u]
diff --git a/src/hb-ot-shape-complex-use-table.cc b/src/hb-ot-shape-complex-use-table.cc index 4ce9010..45c7976 100644 --- a/src/hb-ot-shape-complex-use-table.cc +++ b/src/hb-ot-shape-complex-use-table.cc
@@ -640,6 +640,7 @@ if (hb_in_range (u, 0x0028u, 0x003Fu)) return use_table[u - 0x0028u + use_offset_0x0028u]; if (hb_in_range (u, 0x00A0u, 0x00D7u)) return use_table[u - 0x00A0u + use_offset_0x00a0u]; if (hb_in_range (u, 0x0900u, 0x0DF7u)) return use_table[u - 0x0900u + use_offset_0x0900u]; + if (unlikely (u == 0x034Fu)) return USE_CGJ; break; case 0x1u: