Fix vertical size of emboldened glyphs.

Cf. https://bugzilla.gnome.org/show_bug.cgi?id=686709

* src/base/ftsynth.c (FT_GlyphSlot_Embolden): Adjust `horiBearingY'
also.
* docs/CHANGES: Updated.
[autofit] Disunify Cyrillic and Greek handling from Latin.

* src/autofit/afscript.h: Add Cyrillic and Greek.

* src/autofit/afblue.dat (AF_BLUE_STRINGSET_GREK,
AF_BLUE_STRINGSET_CYRL): Add blue zones for Greek and Cyrillic.
(AF_BLUE_STRINGSET_LATN): Fix typo.
* src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.

* src/autofit/aflatin.c (af_grek_uniranges, af_cyrl_uniranges): New
arrays.
(af_grek_script_class, af_cyrl_script_class): New scripts.
* src/autofit/aflatin.h: Updated.
Fix Savannah bug #40090.

* src/autofit/afcjk.c (af_cjk_metrics_scale): Revert commit
306f8c5d (from 2013-08-25) affecting this function.
[bdf, pcf] Refuse non-zero face_index.
Suggested by Akira Tagoh, see

  http://lists.gnu.org/archive/html/freetype/2013-09/msg00030.html

* src/bdf/bdfdrivr.c (BDF_Face_Init): Return Invalid_Argument error
when the font could be opened but non-zero face_index is given.
* src/pcf/pcfdrivr.c (PCF_Face_Init): Ditto.

* src/type42/t42objs.c (T42_Face_Init): Remove unrequired FT_UNUSED
macro for face_index because it is validated in later.
Minor.
* src/autofit/aflatin.c (af_{grek,cyrl}_uniranges): Fix arrays.
[autofit] Remove outdated comment.
Fix Savannah bug #39295.

The bug was caused by switching to the initial hintmap (the one in
effect when `moveto' executes) just before drawing the final element
in the charstring.  This ensured that the path was closed (in both
Character Space and Device Space).  But if the final element was a
curve and if the final hintmap was different enough from the initial
one, then the curve was visibly distorted.

The first part of the fix is to draw the final curve using the final
hintmap as specified by the charstring.  This corrects the
distortion but does not ensure closing in Device Space.  It may
require the rasterizer to automatically generate an extra closing
line.  Depending on the hintmap differences, this line could be from
zero to a couple pixels in length.

The second part of the fix covers the case where the charstring
subpath is closed with an explicit line.  We now modify that line's
end point to avoid the distortion.

Some glyphs in the bug report font (TexGyreHeros-Regular) that show
the change are:

  25ppem    S (98)
  24ppem    eight (52)
  25.5ppem  p (85)

Curves at the *end* of a subpath are no longer distorted.  However,
some of these glyphs have bad hint substitutions in the middle of a
subpath, and these are not affected.

The patch has been tested with a set of 106 fonts that shipped with
Adobe Creative Suite 4, together with 756 Open Source CFF fonts from
Google Fonts.  There are 1.5 million glyphs, of which some 20k are
changed with the fix.  A sampling of a few hundred of these changes
have been examined more closely, and the changes look good (or at
least acceptable).

* src/cff/cf2hints.h (CF2_GlyphPathRec): New element `pathIsClosing'
to indicate that we synthesize a closepath line.

* src/cff/cf2hints.c (cf2_glyphpath_init): Updated.
(cf2_glyphpath_pushPrevElem): If closing, use first hint map (for
`lineto' operator) and adjust hint zone.
For synthesized closing lines, use end point in first hint zone.
(cf2_glyphpath_lineTo): Take care of synthesized closing lines.  In
particular, shift the detection of zero-length lines from character
space to device space.
(cf2_glyphpath_closeOpenPath): Remove assertion.
Updated.
* src/cff/cf2font.c (cf2_computeDarkening): Initialize darkenAmount.

This line was lost in commit 89ca1fd6 (from 2013-06-25).  The effect
is to use a previous darkening amount when producing an unhinted,
unscaled outline.  This can cause autohint samples in ftgrid and
ftview to be based on darkened CFF outlines instead of unhinted,
undarkened ones.
Merge branch 'master' of git://git.sv.nongnu.org/freetype/freetype2