[svg] Set linear advances when loading SVG glyphs

* include/freetype/freetype.h (FT_GlyphSlotRec_): update doc
* src/cff/cffgload.c (cff_slot_load): do it
* src/truetype/ttgload.c (TT_Load_Glyph): do it

Fixes: #1156
diff --git a/include/freetype/freetype.h b/include/freetype/freetype.h
index aa1a4fe..90e0888 100644
--- a/include/freetype/freetype.h
+++ b/include/freetype/freetype.h
@@ -1892,13 +1892,13 @@
    *     The advance width of the unhinted glyph.  Its value is expressed in
    *     16.16 fractional pixels, unless @FT_LOAD_LINEAR_DESIGN is set when
    *     loading the glyph.  This field can be important to perform correct
-   *     WYSIWYG layout.  Only relevant for outline glyphs.
+   *     WYSIWYG layout.  Only relevant for scalable glyphs.
    *
    *   linearVertAdvance ::
    *     The advance height of the unhinted glyph.  Its value is expressed in
    *     16.16 fractional pixels, unless @FT_LOAD_LINEAR_DESIGN is set when
    *     loading the glyph.  This field can be important to perform correct
-   *     WYSIWYG layout.  Only relevant for outline glyphs.
+   *     WYSIWYG layout.  Only relevant for scalable glyphs.
    *
    *   advance ::
    *     This shorthand is, depending on @FT_LOAD_IGNORE_TRANSFORM, the
diff --git a/src/cff/cffgload.c b/src/cff/cffgload.c
index 7586b88..d8fc318 100644
--- a/src/cff/cffgload.c
+++ b/src/cff/cffgload.c
@@ -404,6 +404,9 @@
                            &dummy,
                            &advanceY );
 
+        glyph->root.linearHoriAdvance = advanceX;
+        glyph->root.linearVertAdvance = advanceY;
+
         advanceX =
           (FT_UShort)FT_MulDiv( advanceX,
                                 glyph->root.face->size->metrics.x_ppem,
diff --git a/src/truetype/ttgload.c b/src/truetype/ttgload.c
index 2ca63d6..e2908d0 100644
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -3005,6 +3005,9 @@
                            &topBearing,
                            &advanceY );
 
+        glyph->linearHoriAdvance = advanceX;
+        glyph->linearVertAdvance = advanceY;
+
         advanceX = (FT_UShort)FT_MulDiv( advanceX,
                                          glyph->face->size->metrics.x_ppem,
                                          glyph->face->units_per_EM );