Class Type0Font


  • public class Type0Font
    extends PDFFont
    Type 0 fonts are composite fonts with a CMAP to map between source character codes and destination fonts/codes
    • Field Detail

      • fonts

        PDFFont[] fonts
        The decendant fonts, indexed by font number from the CMAP
    • Constructor Detail

      • Type0Font

        public Type0Font​(java.lang.String baseFont,
                         PDFObject fontObj,
                         PDFFontDescriptor descriptor)
                  throws java.io.IOException
        Creates a new instance of Type0Font
        Throws:
        java.io.IOException
    • Method Detail

      • getDescendantFont

        public PDFFont getDescendantFont​(int fontID)
        Get a descendant font of this font by fontId
      • getGlyph

        protected PDFGlyph getGlyph​(char src,
                                    java.lang.String name)
        Get a character from the first font in the descendant fonts array
        Specified by:
        getGlyph in class PDFFont
        Parameters:
        src - the character code of this glyph
        name - the name of this glyph or null if unknown
        Returns:
        a glyph for this character