Class Type1CharString

java.lang.Object
org.apache.fontbox.cff.Type1CharString
Direct Known Subclasses:
Type2CharString

public class Type1CharString extends Object
This class represents and renders a Type 1 CharString.
Author:
Villu Ruusmann, John Hewson
  • Field Details

    • type1Sequence

      protected List<Object> type1Sequence
    • commandCount

      protected int commandCount
  • Constructor Details

    • Type1CharString

      public Type1CharString(Type1CharStringReader font, String fontName, String glyphName, List<Object> sequence)
      Constructs a new Type1CharString object.
      Parameters:
      font - Parent Type 1 CharString font.
      fontName - Name of the font.
      glyphName - Name of the glyph.
      sequence - Type 1 char string sequence
    • Type1CharString

      protected Type1CharString(Type1CharStringReader font, String fontName, String glyphName)
      Constructor for use in subclasses.
      Parameters:
      font - Parent Type 1 CharString font.
      fontName - Name of the font.
      glyphName - Name of the glyph.
  • Method Details

    • getName

      public String getName()
    • getBounds

      public Rectangle2D getBounds()
      Returns the bounds of the renderer path.
      Returns:
      the bounds as Rectangle2D
    • getWidth

      public int getWidth()
      Returns the advance width of the glyph.
      Returns:
      the width
    • getPath

      public GeneralPath getPath()
      Returns the path of the character.
      Returns:
      the path
    • getType1Sequence

      public List<Object> getType1Sequence()
      Returns the Type 1 char string sequence.
      Returns:
      the Type 1 sequence
    • toString

      public String toString()
      Overrides:
      toString in class Object