ref: 3a55340029783ec9ab738698e3e3ab2cd74c882e
parent: 55127272c4d67e662e18805917601fe56df8f83f
author: Werner Lemberg <[email protected]>
date: Thu Nov 15 11:37:05 EST 2012
[autofit] Trace stem widths. * src/autofit/aflatin.c (af_latin_metrics_init_widths): Add some FT_TRACE calls.
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2012-11-15 Werner Lemberg <[email protected]>
+
+ [autofit] Trace stem widths.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_widths): Add some
+ FT_TRACE calls.
+
2012-11-13 Werner Lemberg <[email protected]>
[cff] Add support for OpenType Collections (OTC).
--- a/src/autofit/aflatin.c
+++ b/src/autofit/aflatin.c
@@ -60,6 +60,9 @@
AF_GlyphHintsRec hints[1];
+ FT_TRACE5(( "standard widths computation\n"
+ "===========================\n\n" ));
+
af_glyph_hints_init( hints, face->memory );
metrics->axis[AF_DIMENSION_HORZ].width_count = 0;
@@ -78,6 +81,9 @@
if ( glyph_index == 0 )
goto Exit;
+ FT_TRACE5(( "standard character: 0x%X (glyph index %d)\n",
+ metrics->root.clazz->standard_char, glyph_index ));
+
error = FT_Load_Glyph( face, glyph_index, FT_LOAD_NO_SCALE );
if ( error || face->glyph->outline.n_points <= 0 )
goto Exit;
@@ -161,8 +167,27 @@
axis->edge_distance_threshold = stdw / 5;
axis->standard_width = stdw;
axis->extra_light = 0;
+
+#ifdef FT_DEBUG_LEVEL_TRACE
+ {
+ FT_UInt i;
+
+
+ FT_TRACE5(( "%s widths:\n",
+ dim == AF_DIMENSION_VERT ? "horizontal"
+ : "vertical" ));
+
+ FT_TRACE5(( " %d (standard)", axis->standard_width ));
+ for ( i = 1; i < axis->width_count; i++ )
+ FT_TRACE5(( " %d", axis->widths[i].org ));
+
+ FT_TRACE5(( "\n" ));
+ }
+#endif
}
}
+
+ FT_TRACE5(( "\n" ));
af_glyph_hints_done( hints );
}