[arabic-fallback] Add the component loop
Should be able to support 3-letter ligatures now. Hooking up next.
This commit is contained in:
parent
9684d2d8aa
commit
20e9f0b1d2
|
@ -153,13 +153,16 @@ arabic_fallback_synthesize_lookup_ligature (const hb_ot_shape_plan_t *plan HB_UN
|
||||||
const auto &components = ligature_table[first_glyph_idx].ligatures[ligature_idx].components;
|
const auto &components = ligature_table[first_glyph_idx].ligatures[ligature_idx].components;
|
||||||
unsigned component_count = ARRAY_LENGTH_CONST (components);
|
unsigned component_count = ARRAY_LENGTH_CONST (components);
|
||||||
|
|
||||||
hb_codepoint_t component_u = ligature_table[first_glyph_idx].ligatures[ligature_idx].components[0];
|
for (unsigned i = 0; i < component_count; i++)
|
||||||
hb_codepoint_t component_glyph;
|
{
|
||||||
if (!component_u ||
|
hb_codepoint_t component_u = ligature_table[first_glyph_idx].ligatures[ligature_idx].components[i];
|
||||||
!hb_font_get_glyph (font, component_u, 0, &component_glyph))
|
hb_codepoint_t component_glyph;
|
||||||
continue;
|
if (!component_u ||
|
||||||
|
!hb_font_get_glyph (font, component_u, 0, &component_glyph))
|
||||||
|
continue;
|
||||||
|
|
||||||
component_list[num_components++] = component_glyph;
|
component_list[num_components++] = component_glyph;
|
||||||
|
}
|
||||||
|
|
||||||
component_count_list[num_ligatures] = 1 + component_count;
|
component_count_list[num_ligatures] = 1 + component_count;
|
||||||
ligature_list[num_ligatures] = ligature_glyph;
|
ligature_list[num_ligatures] = ligature_glyph;
|
||||||
|
|
Loading…
Reference in New Issue