Add old-Myanmar shaper Looks like Unsicribe responds to the 'mymr' tag by zeroing marks GDEF_LATE instead of generic-shaper UNICODE_LATE. Implement that. Fixes Bug 81775 - Incorrect Rendering with harfbuzz-ng myanmar unicode https://bugs.freedesktop.org/show_bug.cgi?id=81775 Micro-test added based on Padauk.
diff --git a/src/hb-ot-shape-complex-myanmar.cc b/src/hb-ot-shape-complex-myanmar.cc index 258ccc4..d016380 100644 --- a/src/hb-ot-shape-complex-myanmar.cc +++ b/src/hb-ot-shape-complex-myanmar.cc
@@ -536,6 +536,24 @@ } +/* Uniscribe seems to have a shaper for 'mymr' that is like the + * generic shaper, except that it zeros mark advances GDEF_LATE. */ +const hb_ot_complex_shaper_t _hb_ot_complex_shaper_myanmar_old = +{ + "default", + NULL, /* collect_features */ + NULL, /* override_features */ + NULL, /* data_create */ + NULL, /* data_destroy */ + NULL, /* preprocess_text */ + HB_OT_SHAPE_NORMALIZATION_MODE_DEFAULT, + NULL, /* decompose */ + NULL, /* compose */ + NULL, /* setup_masks */ + HB_OT_SHAPE_ZERO_WIDTH_MARKS_BY_GDEF_LATE, + true, /* fallback_position */ +}; + const hb_ot_complex_shaper_t _hb_ot_complex_shaper_myanmar = { "myanmar",