[subset] fix bug in parsing glyf flags.
the bytes of the flag stream were being treated as signed integers instead of unsigned as specified in the spec.
This commit is contained in:
parent
f5a8f747ff
commit
e39c3bde7b
|
@ -509,8 +509,8 @@ struct glyf
|
|||
const Glyph trim_padding () const
|
||||
{
|
||||
/* based on FontTools _g_l_y_f.py::trim */
|
||||
const char *glyph = bytes.arrayZ;
|
||||
const char *glyph_end = glyph + bytes.length;
|
||||
const uint8_t *glyph = (uint8_t*) bytes.arrayZ;
|
||||
const uint8_t *glyph_end = glyph + bytes.length;
|
||||
/* simple glyph w/contours, possibly trimmable */
|
||||
glyph += instruction_len_offset ();
|
||||
|
||||
|
|
|
@ -9,6 +9,7 @@ EXTRA_DIST += \
|
|||
$(TESTS) \
|
||||
expected/basics \
|
||||
expected/full-font \
|
||||
expected/glyf_bug_3131 \
|
||||
expected/cff-full-font \
|
||||
expected/japanese \
|
||||
expected/cff-japanese \
|
||||
|
|
|
@ -9,6 +9,7 @@ TESTS = \
|
|||
tests/colr.tests \
|
||||
tests/colr_with_components.tests \
|
||||
tests/full-font.tests \
|
||||
tests/glyf_bug_3131.tests \
|
||||
tests/japanese.tests \
|
||||
tests/layout.context.tests \
|
||||
tests/layout.gdef-attachlist.tests \
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -0,0 +1,11 @@
|
|||
# Tests for https://github.com/harfbuzz/harfbuzz/issues/3131
|
||||
FONTS:
|
||||
glyf_bug_3131.ttf
|
||||
|
||||
PROFILES:
|
||||
drop-hints-retain-gids.txt
|
||||
retain-gids.txt
|
||||
|
||||
SUBSETS:
|
||||
cdeopqr
|
||||
*
|
|
@ -5,6 +5,7 @@ tests = [
|
|||
'japanese',
|
||||
'cff-japanese',
|
||||
'cff.notoserifmyanmar',
|
||||
'glyf_bug_3131',
|
||||
'layout',
|
||||
'layout.gpos',
|
||||
'layout.gpos2',
|
||||
|
|
Loading…
Reference in New Issue