Class Type2CharStringParser

java.lang.Object
org.apache.fontbox.cff.Type2CharStringParser

public class Type2CharStringParser extends Object
This class represents a converter for a mapping into a Type2-sequence.
Author:
Villu Ruusmann
  • Constructor Details

    • Type2CharStringParser

      public Type2CharStringParser(String fontName)
      Constructs a new Type1CharStringParser object for a Type 1-equivalent font.
      Parameters:
      fontName - font name
  • Method Details

    • parse

      public List<Object> parse(byte[] bytes, byte[][] globalSubrIndex, byte[][] localSubrIndex, String glyphName) throws IOException
      The given byte array will be parsed and converted to a Type2 sequence.
      Parameters:
      bytes - the given mapping as byte array
      globalSubrIndex - array containing all global subroutines
      localSubrIndex - array containing all local subroutines
      glyphName - the name of the current glyph
      Returns:
      the Type2 sequence
      Throws:
      IOException - if an error occurs during reading
    • toString

      public String toString()
      Overrides:
      toString in class Object