From dd305f31f0b483c8e3a74a5a92c0aa2688c5ac7b Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Wed, 9 Dec 2015 21:00:33 +0100 Subject: [PATCH] [autofit] Thinko. * src/autofit/aflatin.c (af_latin_metrics_init_blues): Don't count empty blue zones (bug introduced 2015-12-06). --- ChangeLog | 7 +++++++ src/autofit/aflatin.c | 12 ++++++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 73239bd5c..e1e3462a6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2015-12-09 Werner Lemberg + + [autofit] Thinko. + + * src/autofit/aflatin.c (af_latin_metrics_init_blues): Don't count + empty blue zones (bug introduced 2015-12-06). + 2015-12-09 Werner Lemberg [autofit] Introduce subscript top blue zones. diff --git a/src/autofit/aflatin.c b/src/autofit/aflatin.c index aeaffb88e..b85d6cd3d 100644 --- a/src/autofit/aflatin.c +++ b/src/autofit/aflatin.c @@ -822,10 +822,14 @@ } /* end for loop */ - if ( best_round ) - rounds[num_rounds++] = best_y_extremum; - else - flats[num_flats++] = best_y_extremum; + if ( !( best_y_extremum == FT_INT_MIN || + best_y_extremum == FT_INT_MAX ) ) + { + if ( best_round ) + rounds[num_rounds++] = best_y_extremum; + else + flats[num_flats++] = best_y_extremum; + } } /* end while loop */