shithub: freetype+ttf2subf

Download patch

ref: 70f4cff19d0b555cf4a217de6cd114af750dddcf
parent: 22e970a23e8667aeb0ff6ac1c59ac659ad71059a
author: Werner Lemberg <[email protected]>
date: Sat Sep 20 12:12:05 EDT 2008

* src/smooth/ftgrays.c (gray_find_cell): Fix threshold.  The values
passed to this function are already `normalized'.  Problem reported
by Stephan T. Lavavej  <[email protected]>.

* docs/CHANGES: Document it.

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
 2008-09-20  Werner Lemberg  <[email protected]>
 
+	* src/smooth/ftgrays.c (gray_find_cell): Fix threshold.  The values
+	passed to this function are already `normalized'.  Problem reported
+	by Stephan T. Lavavej  <[email protected]>.
+
+	* docs/CHANGES: Document it.
+
+2008-09-20  Werner Lemberg  <[email protected]>
+
 	* src/base/ftoutln.c: Include FT_INTERNAL_DEBUG_H.
 	(FT_Outline_Decompose): Decorate with tracing messages.
 
@@ -16,7 +24,7 @@
 	(gray_hline) [FT_DEBUG_LEVEL_TRACE]: Fix condition.
 	Use FT_TRACE7.
 	(gray_dump_cells): Make it `static void'.
-	(graay_convert_glyph): Use FT_TRACE7.
+	(gray_convert_glyph): Use FT_TRACE7.
 
 	(FT_Outline_Decompose) [_STANDALONE_]: Synchronize with version in
 	ftoutln.c.
--- a/docs/CHANGES
+++ b/docs/CHANGES
@@ -4,6 +4,12 @@
 
     - CID-keyed fonts in an SFNT wrapper were not handled correctly.
 
+    - The smooth renderer produced truncated images (on the right) for
+      outline parts with negative horizontal values.  Most fonts don't
+      contain outlines left  to the y coordinate axis, but  the effect
+      was very noticeable for outlines processed with FT_Glyph_Stroke,
+      using thick strokes.
+
 
   II. IMPORTANT CHANGES
 
--- a/src/smooth/ftgrays.c
+++ b/src/smooth/ftgrays.c
@@ -431,8 +431,8 @@
     int     x = ras.ex;
 
 
-    if ( x > ras.max_ex )
-      x = ras.max_ex;
+    if ( x > ras.count_ex )
+      x = ras.count_ex;
 
     pcell = &ras.ycells[ras.ey];
     for (;;)