diff options
author | Ewald Hew <ewaldhew@gmail.com> | 2017-10-12 18:13:08 +0800 |
---|---|---|
committer | Ewald Hew <ewaldhew@gmail.com> | 2017-10-12 18:32:50 +0800 |
commit | 78df3c27b651e3de068437ac35ee2214849badb9 (patch) | |
tree | 2c8df4abbef62c434d8d10f53ba079a57e998802 /src/type1 | |
parent | 8768536c89d6bb3e747bc69a7c2c1e58d2ed4aa9 (diff) | |
download | freetype2-78df3c27b651e3de068437ac35ee2214849badb9.tar.gz |
Extract width parsing from Type 1 parser.
Duplicate the fast advance width calculations from the old parser. This
is to facilitate adding options for compiling out the old parser.
* src/psaux/t1decode.{c,h} (t1_decoder_parse_metrics): New function.
* include/freetype/internal/psaux.h (T1_Decoder_Funcs): New entry
`parse_metrics'.
* src/psaux/psauxmod.c: Set the new entry.
* src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String),
src/cid/cidgload.c (cid_load_glyph): Separate
conditional for selecting engine.
Diffstat (limited to 'src/type1')
-rw-r--r-- | src/type1/t1gload.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/type1/t1gload.c b/src/type1/t1gload.c index 30ca186fc..53f89b230 100644 --- a/src/type1/t1gload.c +++ b/src/type1/t1gload.c @@ -90,6 +90,11 @@ decoder, (FT_Byte*)char_string->pointer, (FT_UInt)char_string->length ); + else if ( decoder->builder.metrics_only ) + error = decoder_funcs->parse_metrics( + decoder, + (FT_Byte*)char_string->pointer, + (FT_UInt)char_string->length ); else { CFF_SubFontRec subfont; |