--- ./src/autohint/ahtypes.h.lighthint Tue Sep 24 19:39:58 2002 +++ ./src/autohint/ahtypes.h Thu Jan 2 14:53:59 2003 @@ -496,6 +496,7 @@ FT_Bool do_vert_hints; /* disable Y hinting */ FT_Bool do_horz_snapping; /* disable X stem size snapping */ FT_Bool do_vert_snapping; /* disable Y stem size snapping */ + FT_Bool do_stem_adjust; /* disable light stem snapping */ } AH_HinterRec, *AH_Hinter; --- ./src/autohint/ahhint.c.lighthint Wed Nov 6 17:32:53 2002 +++ ./src/autohint/ahhint.c Thu Jan 2 14:53:59 2003 @@ -104,8 +104,12 @@ sign = 1; } - if ( ( vertical && !hinter->do_vert_snapping ) || - ( !vertical && !hinter->do_horz_snapping ) ) + if ( !hinter->do_stem_adjust ) + { + /* Leave stem widths untouched */ + } + else if ( ( vertical && !hinter->do_vert_snapping ) || + ( !vertical && !hinter->do_horz_snapping ) ) { /* smooth hinting process, very lightly quantize the stem width */ /* */ @@ -1427,6 +1431,8 @@ hinter->do_vert_snapping = FT_BOOL( hint_mode == FT_RENDER_MODE_MONO || hint_mode == FT_RENDER_MODE_LCD_V ); + hinter->do_stem_adjust = FT_BOOL( hint_mode != FT_RENDER_MODE_LIGHT ); + #if 1 load_flags = FT_LOAD_NO_SCALE | FT_LOAD_IGNORE_TRANSFORM ; --- ./src/pshinter/pshalgo3.c.lighthint Tue Sep 17 03:31:17 2002 +++ ./src/pshinter/pshalgo3.c Thu Jan 2 14:55:21 2003 @@ -516,18 +516,21 @@ hint->cur_pos = pos; hint->cur_len = fit_len; - if ( len <= 64 ) - { - /* the stem is less than one pixel, we will center it */ - /* around the nearest pixel center */ - /* */ - pos = ( pos + ( (len >> 1) & -64 ) ); - len = 64; - } - else - { - len = psh3_dimension_quantize_len( dim, len, 0 ); - } + if ( glyph->do_stem_adjust ) + { + if ( len <= 64 ) + { + /* the stem is less than one pixel, we will center it */ + /* around the nearest pixel center */ + /* */ + pos = ( pos + ( (len >> 1) & -64 ) ); + len = 64; + } + else + { + len = psh3_dimension_quantize_len( dim, len, 0 ); + } + } /* now that we have a good hinted stem width, try to position */ /* the stem along a pixel grid integer coordinate */ @@ -1720,6 +1723,8 @@ glyph->do_vert_snapping = FT_BOOL( hint_mode == FT_RENDER_MODE_MONO || hint_mode == FT_RENDER_MODE_LCD_V ); + glyph->do_stem_adjust = FT_BOOL( hint_mode != FT_RENDER_MODE_LIGHT ); + for ( dimension = 0; dimension < 2; dimension++ ) { /* load outline coordinates into glyph */ --- ./src/pshinter/pshalgo3.h.lighthint Sun Sep 8 17:29:11 2002 +++ ./src/pshinter/pshalgo3.h Thu Jan 2 14:53:59 2003 @@ -221,6 +221,7 @@ FT_Bool do_vert_hints; FT_Bool do_horz_snapping; FT_Bool do_vert_snapping; + FT_Bool do_stem_adjust; } PSH3_GlyphRec, *PSH3_Glyph;