diff --git a/ChangeLog b/ChangeLog index c85a698b4..a102c61a4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,24 @@ +2017-02-05 Werner Lemberg + + [autofit] Use better blue zone characters for lowercase latin. + + The number of lowercase characters for computing the top flat blue + zone value was too small (in most cases only `x' and `z'). If one + of the two characters has a large serif, say, it can happen that + FreeType must select between two different values, having a 50% + chance to use the wrong one. As a result, rendering at larger PPEM + values could yield uneven lowercase glyph heights. + + Problem reported by Christoph Koeberlin . + + * src/autofit/afblue.dat (AF_BLUE_STRING_LATIN_SMALL): Replaced + with... + (AF_BLUE_STRING_LATIN_SMALL_TOP, AF_BLUE_STRING_LATIN_SMALL_BOTTOM): + ... New, extended sets. + (AF_BLUE_STRINGSET_LATN): Updated. + + * src/autofit/afblue.c, scr/autofit/afblue.h: Regenerated. + 2017-02-04 Werner Lemberg Make `freetype-config' a wrapper of `pkg-config' if possible. diff --git a/src/autofit/afblue.c b/src/autofit/afblue.c index bbc6dafc2..524f68874 100644 --- a/src/autofit/afblue.c +++ b/src/autofit/afblue.c @@ -168,7 +168,9 @@ '\0', 'f', ' ', 'i', ' ', 'j', ' ', 'k', ' ', 'd', ' ', 'b', ' ', 'h', /* f i j k d b h */ '\0', - 'x', ' ', 'z', ' ', 'r', ' ', 'o', ' ', 'e', ' ', 's', ' ', 'c', /* x z r o e s c */ + 'u', ' ', 'v', ' ', 'x', ' ', 'z', ' ', 'o', ' ', 'e', ' ', 's', ' ', 'c', /* u v x z o e s c */ + '\0', + 'n', ' ', 'r', ' ', 'x', ' ', 'z', ' ', 'o', ' ', 'e', ' ', 's', ' ', 'c', /* n r x z o e s c */ '\0', 'p', ' ', 'q', ' ', 'g', ' ', 'j', ' ', 'y', /* p q g j y */ '\0', @@ -392,9 +394,9 @@ { AF_BLUE_STRING_LATIN_CAPITAL_TOP, AF_BLUE_PROPERTY_LATIN_TOP }, { AF_BLUE_STRING_LATIN_CAPITAL_BOTTOM, 0 }, { AF_BLUE_STRING_LATIN_SMALL_F_TOP, AF_BLUE_PROPERTY_LATIN_TOP }, - { AF_BLUE_STRING_LATIN_SMALL, AF_BLUE_PROPERTY_LATIN_TOP | + { AF_BLUE_STRING_LATIN_SMALL_TOP, AF_BLUE_PROPERTY_LATIN_TOP | AF_BLUE_PROPERTY_LATIN_X_HEIGHT }, - { AF_BLUE_STRING_LATIN_SMALL, 0 }, + { AF_BLUE_STRING_LATIN_SMALL_BOTTOM, 0 }, { AF_BLUE_STRING_LATIN_SMALL_DESCENDER, 0 }, { AF_BLUE_STRING_MAX, 0 }, { AF_BLUE_STRING_LATIN_SUBS_CAPITAL_TOP, AF_BLUE_PROPERTY_LATIN_TOP }, diff --git a/src/autofit/afblue.dat b/src/autofit/afblue.dat index d5a9ef5bf..8b75aecf3 100644 --- a/src/autofit/afblue.dat +++ b/src/autofit/afblue.dat @@ -242,8 +242,10 @@ AF_BLUE_STRING_ENUM AF_BLUE_STRINGS_ARRAY AF_BLUE_STRING_MAX_LEN: "H E Z L O C U S" AF_BLUE_STRING_LATIN_SMALL_F_TOP "f i j k d b h" - AF_BLUE_STRING_LATIN_SMALL - "x z r o e s c" + AF_BLUE_STRING_LATIN_SMALL_TOP + "u v x z o e s c" + AF_BLUE_STRING_LATIN_SMALL_BOTTOM + "n r x z o e s c" AF_BLUE_STRING_LATIN_SMALL_DESCENDER "p q g j y" @@ -630,9 +632,9 @@ AF_BLUE_STRINGSET_ENUM AF_BLUE_STRINGSETS_ARRAY AF_BLUE_STRINGSET_MAX_LEN: { AF_BLUE_STRING_LATIN_CAPITAL_TOP, AF_BLUE_PROPERTY_LATIN_TOP } { AF_BLUE_STRING_LATIN_CAPITAL_BOTTOM, 0 } { AF_BLUE_STRING_LATIN_SMALL_F_TOP, AF_BLUE_PROPERTY_LATIN_TOP } - { AF_BLUE_STRING_LATIN_SMALL, AF_BLUE_PROPERTY_LATIN_TOP | + { AF_BLUE_STRING_LATIN_SMALL_TOP, AF_BLUE_PROPERTY_LATIN_TOP | AF_BLUE_PROPERTY_LATIN_X_HEIGHT } - { AF_BLUE_STRING_LATIN_SMALL, 0 } + { AF_BLUE_STRING_LATIN_SMALL_BOTTOM, 0 } { AF_BLUE_STRING_LATIN_SMALL_DESCENDER, 0 } { AF_BLUE_STRING_MAX, 0 } diff --git a/src/autofit/afblue.h b/src/autofit/afblue.h index 12381ea0e..f4720edd5 100644 --- a/src/autofit/afblue.h +++ b/src/autofit/afblue.h @@ -148,39 +148,40 @@ FT_BEGIN_HEADER AF_BLUE_STRING_LATIN_CAPITAL_TOP = 1852, AF_BLUE_STRING_LATIN_CAPITAL_BOTTOM = 1868, AF_BLUE_STRING_LATIN_SMALL_F_TOP = 1884, - AF_BLUE_STRING_LATIN_SMALL = 1898, - AF_BLUE_STRING_LATIN_SMALL_DESCENDER = 1912, - AF_BLUE_STRING_LATIN_SUBS_CAPITAL_TOP = 1922, - AF_BLUE_STRING_LATIN_SUBS_CAPITAL_BOTTOM = 1942, - AF_BLUE_STRING_LATIN_SUBS_SMALL_F_TOP = 1962, - AF_BLUE_STRING_LATIN_SUBS_SMALL = 1982, - AF_BLUE_STRING_LATIN_SUBS_SMALL_DESCENDER = 2018, - AF_BLUE_STRING_LATIN_SUPS_CAPITAL_TOP = 2038, - AF_BLUE_STRING_LATIN_SUPS_CAPITAL_BOTTOM = 2069, - AF_BLUE_STRING_LATIN_SUPS_SMALL_F_TOP = 2098, - AF_BLUE_STRING_LATIN_SUPS_SMALL = 2124, - AF_BLUE_STRING_LATIN_SUPS_SMALL_DESCENDER = 2149, - AF_BLUE_STRING_MALAYALAM_TOP = 2160, - AF_BLUE_STRING_MALAYALAM_BOTTOM = 2204, - AF_BLUE_STRING_MYANMAR_TOP = 2236, - AF_BLUE_STRING_MYANMAR_BOTTOM = 2268, - AF_BLUE_STRING_MYANMAR_ASCENDER = 2300, - AF_BLUE_STRING_MYANMAR_DESCENDER = 2328, - AF_BLUE_STRING_SINHALA_TOP = 2360, - AF_BLUE_STRING_SINHALA_BOTTOM = 2392, - AF_BLUE_STRING_SINHALA_DESCENDER = 2424, - AF_BLUE_STRING_TAMIL_TOP = 2468, - AF_BLUE_STRING_TAMIL_BOTTOM = 2500, - AF_BLUE_STRING_TELUGU_TOP = 2532, - AF_BLUE_STRING_TELUGU_BOTTOM = 2560, - AF_BLUE_STRING_THAI_TOP = 2588, - AF_BLUE_STRING_THAI_BOTTOM = 2612, - AF_BLUE_STRING_THAI_ASCENDER = 2640, - AF_BLUE_STRING_THAI_LARGE_ASCENDER = 2652, - AF_BLUE_STRING_THAI_DESCENDER = 2664, - AF_BLUE_STRING_THAI_LARGE_DESCENDER = 2680, - AF_BLUE_STRING_THAI_DIGIT_TOP = 2688, - af_blue_1_1 = 2699, + AF_BLUE_STRING_LATIN_SMALL_TOP = 1898, + AF_BLUE_STRING_LATIN_SMALL_BOTTOM = 1914, + AF_BLUE_STRING_LATIN_SMALL_DESCENDER = 1930, + AF_BLUE_STRING_LATIN_SUBS_CAPITAL_TOP = 1940, + AF_BLUE_STRING_LATIN_SUBS_CAPITAL_BOTTOM = 1960, + AF_BLUE_STRING_LATIN_SUBS_SMALL_F_TOP = 1980, + AF_BLUE_STRING_LATIN_SUBS_SMALL = 2000, + AF_BLUE_STRING_LATIN_SUBS_SMALL_DESCENDER = 2036, + AF_BLUE_STRING_LATIN_SUPS_CAPITAL_TOP = 2056, + AF_BLUE_STRING_LATIN_SUPS_CAPITAL_BOTTOM = 2087, + AF_BLUE_STRING_LATIN_SUPS_SMALL_F_TOP = 2116, + AF_BLUE_STRING_LATIN_SUPS_SMALL = 2142, + AF_BLUE_STRING_LATIN_SUPS_SMALL_DESCENDER = 2167, + AF_BLUE_STRING_MALAYALAM_TOP = 2178, + AF_BLUE_STRING_MALAYALAM_BOTTOM = 2222, + AF_BLUE_STRING_MYANMAR_TOP = 2254, + AF_BLUE_STRING_MYANMAR_BOTTOM = 2286, + AF_BLUE_STRING_MYANMAR_ASCENDER = 2318, + AF_BLUE_STRING_MYANMAR_DESCENDER = 2346, + AF_BLUE_STRING_SINHALA_TOP = 2378, + AF_BLUE_STRING_SINHALA_BOTTOM = 2410, + AF_BLUE_STRING_SINHALA_DESCENDER = 2442, + AF_BLUE_STRING_TAMIL_TOP = 2486, + AF_BLUE_STRING_TAMIL_BOTTOM = 2518, + AF_BLUE_STRING_TELUGU_TOP = 2550, + AF_BLUE_STRING_TELUGU_BOTTOM = 2578, + AF_BLUE_STRING_THAI_TOP = 2606, + AF_BLUE_STRING_THAI_BOTTOM = 2630, + AF_BLUE_STRING_THAI_ASCENDER = 2658, + AF_BLUE_STRING_THAI_LARGE_ASCENDER = 2670, + AF_BLUE_STRING_THAI_DESCENDER = 2682, + AF_BLUE_STRING_THAI_LARGE_DESCENDER = 2698, + AF_BLUE_STRING_THAI_DIGIT_TOP = 2706, + af_blue_1_1 = 2717, #ifdef AF_CONFIG_OPTION_CJK AF_BLUE_STRING_CJK_TOP = af_blue_1_1 + 1, AF_BLUE_STRING_CJK_BOTTOM = af_blue_1_1 + 203,