[cairo-commit] src/cairo-ft-font.c

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Jul 26 21:52:57 UTC 2019


 src/cairo-ft-font.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 52a7c79fd4ff96bb5fac175f0199819b0f8c18fc
Author: Matthias Clasen <mclasen at redhat.com>
Date:   Fri Jul 26 17:29:17 2019 -0400

    Fix vertical subpixel positioning
    
    We need to apply the Y subpixel phase negated,
    since we flip the Y axis later.

diff --git a/src/cairo-ft-font.c b/src/cairo-ft-font.c
index 7db16e8bd..6ae60b457 100644
--- a/src/cairo-ft-font.c
+++ b/src/cairo-ft-font.c
@@ -2455,14 +2455,13 @@ _cairo_ft_scaled_glyph_load_glyph (cairo_ft_scaled_font_t *scaled_font,
     if (vertical_layout)
 	_cairo_ft_scaled_glyph_vertical_layout_bearing_fix (scaled_font, face->glyph);
 
-
     if (face->glyph->format == FT_GLYPH_FORMAT_OUTLINE) {
         FT_Pos xshift, yshift;
 
         xshift = _cairo_scaled_glyph_xphase (scaled_glyph) << 4;
         yshift = _cairo_scaled_glyph_yphase (scaled_glyph) << 4;
 
-        FT_Outline_Translate (&face->glyph->outline, xshift, yshift);
+        FT_Outline_Translate (&face->glyph->outline, xshift, -yshift);
     }
 
     return CAIRO_STATUS_SUCCESS;


More information about the cairo-commit mailing list