[paint] Fix drawing non-color glyphs
This commit is contained in:
parent
237955dffc
commit
f3985d9482
|
@ -335,15 +335,11 @@ struct glyf_accelerator_t
|
|||
|
||||
bool paint_glyph (hb_font_t *font, hb_codepoint_t gid, hb_paint_funcs_t *funcs, void *data, hb_color_t foreground) const
|
||||
{
|
||||
funcs->push_root_transform (data, font);
|
||||
|
||||
funcs->push_clip_glyph (data, gid, font);
|
||||
funcs->color (data, true, foreground);
|
||||
funcs->pop_clip (data);
|
||||
|
||||
funcs->pop_root_transform (data);
|
||||
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
const glyf_impl::Glyph
|
||||
|
|
|
@ -555,15 +555,11 @@ bool _get_path (const OT::cff1::accelerator_t *cff, hb_font_t *font, hb_codepoin
|
|||
|
||||
bool OT::cff1::accelerator_t::paint_glyph (hb_font_t *font, hb_codepoint_t glyph, hb_paint_funcs_t *funcs, void *data, hb_color_t foreground) const
|
||||
{
|
||||
funcs->push_root_transform (data, font);
|
||||
|
||||
funcs->push_clip_glyph (data, glyph, font);
|
||||
funcs->color (data, true, foreground);
|
||||
funcs->pop_clip (data);
|
||||
|
||||
funcs->pop_root_transform (data);
|
||||
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool OT::cff1::accelerator_t::get_path (hb_font_t *font, hb_codepoint_t glyph, hb_draw_session_t &draw_session) const
|
||||
|
|
|
@ -145,15 +145,11 @@ bool OT::cff2::accelerator_t::get_extents (hb_font_t *font,
|
|||
|
||||
bool OT::cff2::accelerator_t::paint_glyph (hb_font_t *font, hb_codepoint_t glyph, hb_paint_funcs_t *funcs, void *data, hb_color_t foreground) const
|
||||
{
|
||||
funcs->push_root_transform (data, font);
|
||||
|
||||
funcs->push_clip_glyph (data, glyph, font);
|
||||
funcs->color (data, true, foreground);
|
||||
funcs->pop_clip (data);
|
||||
|
||||
funcs->pop_root_transform (data);
|
||||
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
struct cff2_path_param_t
|
||||
|
|
Loading…
Reference in New Issue