]> git.imager.perl.org - imager.git/commitdiff
fix calculation of descender for FT2, it was calculating the minimum
authorTony Cook <tony@develop=help.com>
Fri, 11 Jan 2002 01:11:17 +0000 (01:11 +0000)
committerTony Cook <tony@develop=help.com>
Fri, 11 Jan 2002 01:11:17 +0000 (01:11 +0000)
decent rather than the maximum for the characters in the string

Changes
freetyp2.c

diff --git a/Changes b/Changes
index a33a5db6506fa40de72b626af200608305efb3e2..0d14c02e674872741f441873063009f463b3965e 100644 (file)
--- a/Changes
+++ b/Changes
@@ -586,6 +586,9 @@ Revision history for Perl extension Imager.
         - use the glyph bbox to calculate the glyph bitmaps for rendering
           with FT1 rather than the global ascender/descender.  This helps
           with fonts that have broken metrics.
+       - fix calculation of descender for FT2, it was calculating the
+         minimum decent rather than the maximum for the characters in 
+         the string
 
 =================================================================
 
index a7c1528ec8cac077bb1df5a8a406045020cb12e3..b933060c9d831e0c6c9d1c2cb9ac8d21f683b005 100644 (file)
@@ -343,7 +343,7 @@ i_ft2_bbox(FT2_Fonthandle *handle, double cheight, double cwidth,
 
     if (glyph_ascent > ascent)
       ascent = glyph_ascent;
-    if (glyph_descent > descent)
+    if (glyph_descent < descent)
       descent = glyph_descent;
 
     width += gm->horiAdvance / 64;