shithub: freetype+ttf2subf

Download patch

ref: c4b22144d32f49e80aead31cff286d0653ab3ad0
parent: c0aeef4571915f9324fe2018507219d9bb31e9e1
author: Werner Lemberg <[email protected]>
date: Sun Nov 15 05:10:00 EST 2009

Add tracing messages for advance values.

* src/base/ftobjs.c (FT_Load_Glyph), src/truetype/ttgload.c
(TT_Get_HMetrics, TT_Get_VMetrics): Do it.

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2009-11-15  Werner Lemberg  <[email protected]>
+
+	Add tracing messages for advance values.
+
+	* src/base/ftobjs.c (FT_Load_Glyph), src/truetype/ttgload.c
+	(TT_Get_HMetrics, TT_Get_VMetrics): Do it.
+
 2009-11-08  Werner Lemberg  <[email protected]>
 
 	Fix compiler warning.
--- a/src/base/ftobjs.c
+++ b/src/base/ftobjs.c
@@ -744,6 +744,12 @@
       }
     }
 
+    FT_TRACE5(( "  x advance: %d\n" , slot->advance.x ));
+    FT_TRACE5(( "  y advance: %d\n" , slot->advance.y ));
+
+    FT_TRACE5(( "  linear x advance: %d\n" , slot->linearHoriAdvance ));
+    FT_TRACE5(( "  linear y advance: %d\n" , slot->linearVertAdvance ));
+
     /* do we need to render the image now? */
     if ( !error                                    &&
          slot->format != FT_GLYPH_FORMAT_BITMAP    &&
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -80,6 +80,9 @@
 
     if ( check && face->postscript.isFixedPitch )
       *aw = face->horizontal.advance_Width_Max;
+
+    FT_TRACE5(( "  advance width (font units): %d\n", *aw ));
+    FT_TRACE5(( "  left side bearing (font units): %d\n", *lsb ));
   }
 
 
@@ -131,6 +134,8 @@
 
 #endif
 
+    FT_TRACE5(( "  advance height (font units): %d\n", *ah ));
+    FT_TRACE5(( "  top side bearing (font units): %d\n", *tsb ));
   }