Skip to content

Commit

Permalink
Tweak mark-base attachment
Browse files Browse the repository at this point in the history
Apparently a base glyph can also become an attached component of a
ligature if the ligature-forming lookup used IgnoreBase.  This was
being confused with a non-first component of a MultipleSubst and
hence not matched for mark-attachment.  Tweak test to fix.

Fixes #543
  • Loading branch information
behdad committed Oct 3, 2017
1 parent ea77293 commit 5d98de1
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/hb-ot-layout-gpos-table.hh
Original file line number Diff line number Diff line change
Expand Up @@ -1087,7 +1087,9 @@ struct MarkBasePosFormat1
do {
if (!skippy_iter.prev ()) return_trace (false);
/* We only want to attach to the first of a MultipleSubst sequence. Reject others. */
if (0 == _hb_glyph_info_get_lig_comp (&buffer->info[skippy_iter.idx])) break;
if (!_hb_glyph_info_multiplied (&buffer->info[skippy_iter.idx]) ||
0 == _hb_glyph_info_get_lig_comp (&buffer->info[skippy_iter.idx]))
break;
skippy_iter.reject ();
} while (1);

Expand Down
1 change: 1 addition & 0 deletions test/shaping/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ TESTS = \
tests/indic-syllable.tests \
tests/language-tags.tests \
tests/ligature-id.tests \
tests/mark-attachment.tests \
tests/mark-filtering-sets.tests \
tests/mongolian-variation-selector.tests \
tests/spaces.tests \
Expand Down
Binary file not shown.
1 change: 1 addition & 0 deletions test/shaping/tests/mark-attachment.tests
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fonts/sha1sum/98b7887cff91f722b92a8ff800120954606354f9.ttf::U+100F,U+103C,U+102F,U+1036:[uni103C102F=0+150|uni100F=0+550|uni1036=0@-150,0+0]

0 comments on commit 5d98de1

Please sign in to comment.