mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-29 09:34:05 +01:00
[subset] MATH: don't serialize coverage table when iterator is empty
when iterator is empty, just set coverage offset to 0. serialize() in coverage will at lease write out a 16-bit format header.
This commit is contained in:
1 parent
1d9ef3a75a
commit
74b46b29e7
11 files changed
+22
-3
No files matched your search
@@ -511,7 +511,8 @@ struct MathGlyphInfo
|
||||
| hb_map_retains_sorting (glyph_map)
|
||||
;
|
||||
|
||||
out->extendedShapeCoverage.serialize_serialize (c->serializer, it);
|
||||
if (it) out->extendedShapeCoverage.serialize_serialize (c->serializer, it);
|
||||
else out->extendedShapeCoverage = 0;
|
||||
|
||||
out->mathKernInfo.serialize_subset (c, mathKernInfo, this);
|
||||
return_trace (true);
|
||||
@@ -884,8 +885,11 @@ struct MathVariants
|
||||
if (!o) return_trace (false);
|
||||
o->serialize_subset (c, glyphConstruction[i], this);
|
||||
}
|
||||
|
||||
out->vertGlyphCoverage.serialize_serialize (c->serializer, new_vert_coverage.iter ());
|
||||
|
||||
if (new_vert_coverage)
|
||||
out->vertGlyphCoverage.serialize_serialize (c->serializer, new_vert_coverage.iter ());
|
||||
|
||||
if (new_hori_coverage)
|
||||
out->horizGlyphCoverage.serialize_serialize (c->serializer, new_hori_coverage.iter ());
|
||||
return_trace (true);
|
||||
}
|
||||
|
||||
@@ -52,6 +52,7 @@ EXTRA_DIST += \
|
||||
expected/variable \
|
||||
expected/glyph_names \
|
||||
expected/math \
|
||||
expected/math_coverage_offset \
|
||||
expected/post \
|
||||
fonts \
|
||||
profiles \
|
||||
|
||||
@@ -44,6 +44,7 @@ TESTS = \
|
||||
tests/variable.tests \
|
||||
tests/glyph_names.tests \
|
||||
tests/math.tests \
|
||||
tests/math_coverage_offset.tests \
|
||||
tests/post.tests \
|
||||
$(NULL)
|
||||
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,12 @@
|
||||
FONTS:
|
||||
Caudex-Regular.ttf
|
||||
|
||||
PROFILES:
|
||||
default.txt
|
||||
retain-gids.txt
|
||||
glyph-names.txt
|
||||
notdef-outline.txt
|
||||
keep-all-layout-features.txt
|
||||
|
||||
SUBSETS:
|
||||
*
|
||||
@@ -39,6 +39,7 @@ tests = [
|
||||
'sbix',
|
||||
'colr',
|
||||
'math',
|
||||
'math_coverage_offset',
|
||||
# TODO: re-enable once colrv1 subsetting is stabilized.
|
||||
# 'colrv1.notoemoji',
|
||||
'colrv1',
|
||||
|
||||
Reference in new issue
Block a user