summaryrefslogtreecommitdiff
path: root/src/sfnt/sfobjs.c
diff options
context:
space:
mode:
authorDominik Röttsches <drott@chromium.org>2022-08-19 19:07:42 +0300
committerWerner Lemberg <wl@gnu.org>2022-09-05 10:36:22 +0200
commita1017e2655360923227f4e8a261497a93867a9a6 (patch)
treec495308bc69d966bff0f960b468ad9e549d0fdf6 /src/sfnt/sfobjs.c
parentdd91f6e7f5a051818070c49715125fb72074023e (diff)
downloadfreetype2-a1017e2655360923227f4e8a261497a93867a9a6.tar.gz
[sfnt] Don't require 'gvar' table to support variation fonts.
Fixes #1172. * src/sfnt/sfobjs.c (sfnt_load_face): Tag font as Multiple Masters font if `fvar` is present; do not require other tables to be present. * src/truetype/ttgxvar.c (tt_set_mm_blend): Allow for a missing 'gvar' table when setting variation coordinates. However, if a 'gvar' table is actually present, do perform a sanity check and fail on malformedness. (TT_Get_MM_Var): Don't assume 'fvar' needs 'gvar' or 'CFF2 tables in all cases, which is an overly tight check.
Diffstat (limited to 'src/sfnt/sfobjs.c')
-rw-r--r--src/sfnt/sfobjs.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/sfnt/sfobjs.c b/src/sfnt/sfobjs.c
index a0da984e7..2f87d2429 100644
--- a/src/sfnt/sfobjs.c
+++ b/src/sfnt/sfobjs.c
@@ -1107,13 +1107,7 @@
/* Don't bother to load the tables unless somebody asks for them. */
/* No need to do work which will (probably) not be used. */
if ( face->variation_support & TT_FACE_FLAG_VAR_FVAR )
- {
- if ( tt_face_lookup_table( face, TTAG_glyf ) != 0 &&
- tt_face_lookup_table( face, TTAG_gvar ) != 0 )
- flags |= FT_FACE_FLAG_MULTIPLE_MASTERS;
- if ( tt_face_lookup_table( face, TTAG_CFF2 ) != 0 )
- flags |= FT_FACE_FLAG_MULTIPLE_MASTERS;
- }
+ flags |= FT_FACE_FLAG_MULTIPLE_MASTERS;
#endif
root->face_flags = flags;