mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-22 23:41:03 +01:00
[outline] Widen origin negation
Synthetic slant translates outlines by the negated glyph origin. Convert the full-range position to the float coordinate domain before negating it, avoiding signed integer overflow at INT_MIN. Tested with: meson test -C build --print-errorlogs Assisted-by: OpenAI Codex
This commit is contained in:
1 parent
91bcdb6653
commit
be40d16869
1 file changed
+1
-1
+1
-1
@@ -738,7 +738,7 @@ struct hb_font_t
|
||||
{
|
||||
hb_position_t xo = 0, yo = 0;
|
||||
get_glyph_h_origin (glyph, &xo, &yo, false);
|
||||
outline.translate (-xo, -yo);
|
||||
outline.translate (-(float) xo, -(float) yo);
|
||||
outline.slant (slant_xy);
|
||||
outline.translate (xo, yo);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user