[ot-font] Respect VORG even if it has no variations

pull/3707/head
Behdad Esfahbod 2 years ago
parent 71d52e10aa
commit b07fa2bb1a
  1. 12
      src/hb-ot-font.cc

@ -298,19 +298,15 @@ hb_ot_get_glyph_v_origin (hb_font_t *font,
#ifndef HB_NO_VAR
const OT::vmtx_accelerator_t &vmtx = *ot_face->vmtx;
const OT::VVAR &VVAR = *vmtx.var_table;
if (font->num_coords &&
!VVAR.get_vorg_var (glyph,
font->coords, font->num_coords,
&delta))
goto out;
if (font->num_coords)
VVAR.get_vorg_var (glyph,
font->coords, font->num_coords,
&delta);
#endif
*y = font->em_scalef_y (VORG.get_y_origin (glyph) + delta);
return true;
}
#ifndef HB_NO_VAR
out:
#endif
hb_glyph_extents_t extents = {0};
if (ot_face->glyf->get_extents (font, glyph, &extents))

Loading…
Cancel
Save