Commit Graph

13 Commits

Author SHA1 Message Date
Behdad Esfahbod fe4e9bd930 [colr] Add public vtable for hb_color_line_t 2022-12-23 13:37:59 -07:00
Matthias Clasen 6387004cad [paint] Simplify api
Drop the hb_paint_context_t struct from the API, and
only pass the font where we need it.
2022-12-23 13:37:59 -07:00
Matthias Clasen 71bd5a0dfc [paint] Resolve colors
We don't need to pass the index/alpha pairs to
client callbacks, and can just resolve the colors
internally.

Update test results.
2022-12-23 13:37:59 -07:00
Matthias Clasen 9be01b6bff [paint] Pass hb_paint_context_t along
Replace the font argument with a hb_paint_context_t
that carries the font, the palette index and the
foreground color.

The hb_font_paint_glyph() api now takes the palette
index and the foreground color as extra arguments.

Update all callers and regenerate test results.
2022-12-23 13:37:59 -07:00
Behdad Esfahbod 6c71c530ca [paint] Rename hb_paint_context_t to hb_ot_paint_context_t 2022-12-23 13:37:59 -07:00
Matthias Clasen 97224f3b63 [paint] Pass font to all callbacks
This will lead to easier implementations.

At the same time, we change the push_clip_glyph
callback to use the font as-is, no unscaling needed.

Update all callers and expected test results.
2022-12-23 13:37:59 -07:00
Matthias Clasen 451414a27e [paint] Documentation fixes 2022-12-23 13:37:59 -07:00
Matthias Clasen 4c728e952b [colr] Add a todo 2022-12-23 13:37:59 -07:00
Behdad Esfahbod b9314400ec [colr] Hook up color-line variation 2022-12-23 13:37:59 -07:00
Behdad Esfahbod c6dd56cc64 [colr] Simplify color-stop handling 2022-12-23 13:37:59 -07:00
Behdad Esfahbod b722039c48 [colr] Simplify 2022-12-23 13:37:59 -07:00
Behdad Esfahbod 46286275f7 [colr] More dispatch functionality 2022-12-23 13:37:59 -07:00
Matthias Clasen 55ca6ed230 minor fixes 2022-12-23 13:37:59 -07:00