Package com.tom_roush.fontbox.cff
Class Type2CharStringParser
- java.lang.Object
-
- com.tom_roush.fontbox.cff.Type2CharStringParser
-
public class Type2CharStringParser extends Object
This class represents a converter for a mapping into a Type2-sequence.
-
-
Constructor Summary
Constructors Constructor Description Type2CharStringParser(String fontName, int cid)Constructs a new Type1CharStringParser object for a CID-Keyed font.Type2CharStringParser(String fontName, String glyphName)Constructs a new Type1CharStringParser object for a Type 1-equivalent font.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Object>parse(byte[] bytes, byte[][] globalSubrIndex, byte[][] localSubrIndex)The given byte array will be parsed and converted to a Type2 sequence.
-
-
-
Constructor Detail
-
Type2CharStringParser
public Type2CharStringParser(String fontName, String glyphName)
Constructs a new Type1CharStringParser object for a Type 1-equivalent font.- Parameters:
fontName- font nameglyphName- glyph name
-
Type2CharStringParser
public Type2CharStringParser(String fontName, int cid)
Constructs a new Type1CharStringParser object for a CID-Keyed font.- Parameters:
fontName- font namecid- CID
-
-
Method Detail
-
parse
public List<Object> parse(byte[] bytes, byte[][] globalSubrIndex, byte[][] localSubrIndex) throws IOException
The given byte array will be parsed and converted to a Type2 sequence.- Parameters:
bytes- the given mapping as byte arrayglobalSubrIndex- array containing all global subroutineslocalSubrIndex- array containing all local subroutines- Returns:
- the Type2 sequence
- Throws:
IOException- if an error occurs during reading
-
-