Unhide CGJ before ccc=0 characters

If a CGJ precedes a starter, then it cannot have blocked any reordering,
so it can safely be skipped.
This commit is contained in:
David Corbett 2019-05-03 18:28:18 -04:00 committed by Behdad Esfahbod
parent 9825e3dd2e
commit 645f4e7cdd
1 changed files with 1 additions and 1 deletions

View File

@ -408,7 +408,7 @@ _hb_ot_shape_normalize (const hb_ot_shape_plan_t *plan,
*/
for (unsigned int i = 1; i + 1 < buffer->len; i++)
if (buffer->info[i].codepoint == 0x034Fu/*CGJ*/ &&
info_cc(buffer->info[i-1]) <= info_cc(buffer->info[i+1]))
(info_cc(buffer->info[i+1]) == 0 || info_cc(buffer->info[i-1]) <= info_cc(buffer->info[i+1])))
{
_hb_glyph_info_unhide (&buffer->info[i]);
}