Class PDTrueTypeFont


  • public class PDTrueTypeFont
    extends PDSimpleFont
    Represents True Type font on PD level.
    Author:
    Sergey Shemyakov
    • Constructor Detail

      • PDTrueTypeFont

        public PDTrueTypeFont​(COSDictionary dictionary)
        Constructor from true type font dictionary.
        Parameters:
        dictionary - is true type font dictionary.
    • Method Detail

      • getWidthFromProgram

        public float getWidthFromProgram​(int code)
        Description copied from class: PDFont
        Gets width of given code from font program.
        Specified by:
        getWidthFromProgram in class PDFont
        Parameters:
        code - is code of character in strings to display.
        Returns:
        width of glyph for this code.
      • glyphIsPresent

        public boolean glyphIsPresent​(int code)
        Description copied from class: PDFont
        Checks if glyph for given code is present in this font.
        Specified by:
        glyphIsPresent in class PDFont
        Parameters:
        code - is code for glyph in this font.
        Returns:
        true if glyph is present.