From e20035ae3ccd24dea3bf111a7b2a6ea6b20953ca Mon Sep 17 00:00:00 2001 From: Tom Kacvinsky Date: Mon, 5 Mar 2001 16:22:25 +0000 Subject: [PATCH] 2001-03-05 Tom Kacvinsky * src/cff/cffgload.c (CFF_Load_Glyph): Set glyph control data to the the Type 2 glyph charstring (used by conversion programs). Submitted by Ha Shao . --- src/cff/cffgload.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/cff/cffgload.c b/src/cff/cffgload.c index 7b96e6801..480562607 100644 --- a/src/cff/cffgload.c +++ b/src/cff/cffgload.c @@ -2137,10 +2137,19 @@ &charstring, &charstring_len ); if ( !error ) { + CFF_Index csindex = cff->charstrings_index; + CFF_Prepare_Decoder( &decoder, glyph_index ); error = CFF_Parse_CharStrings( &decoder, charstring, charstring_len ); CFF_Forget_Element( &cff->charstrings_index, &charstring ); + + /* We set control_data and control_len if charstrings is loaded. */ + /* See how charstring loads at CFF_Access_Element() in cffload.c. */ + + glyph->root.control_data = csindex.bytes + csindex.offsets[glyph_index] - 1; + glyph->root.control_len = charstring_len; + } /* save new glyph tables */