Class TrueTypeFontSubSet

java.lang.Object
com.aowagie.text.pdf.TrueTypeFontSubSet

class TrueTypeFontSubSet extends Object
Subsets a True Type font by removing the unneeded glyphs from the font.
  • Field Details

    • tableNamesSimple

      private static final String[] tableNamesSimple
    • tableNamesCmap

      private static final String[] tableNamesCmap
    • tableNamesExtra

      private static final String[] tableNamesExtra
    • entrySelectors

      private static final int[] entrySelectors
    • TABLE_CHECKSUM

      private static final int TABLE_CHECKSUM
      See Also:
    • TABLE_OFFSET

      private static final int TABLE_OFFSET
      See Also:
    • TABLE_LENGTH

      private static final int TABLE_LENGTH
      See Also:
    • HEAD_LOCA_FORMAT_OFFSET

      static final int HEAD_LOCA_FORMAT_OFFSET
      See Also:
    • ARG_1_AND_2_ARE_WORDS

      private static final int ARG_1_AND_2_ARE_WORDS
      See Also:
    • WE_HAVE_A_SCALE

      private static final int WE_HAVE_A_SCALE
      See Also:
    • MORE_COMPONENTS

      private static final int MORE_COMPONENTS
      See Also:
    • WE_HAVE_AN_X_AND_Y_SCALE

      private static final int WE_HAVE_AN_X_AND_Y_SCALE
      See Also:
    • WE_HAVE_A_TWO_BY_TWO

      private static final int WE_HAVE_A_TWO_BY_TWO
      See Also:
    • tableDirectory

      private HashMap tableDirectory
      Contains the location of the several tables. The key is the name of the table and the value is an int[3] where position 0 is the checksum, position 1 is the offset from the start of the file and position 2 is the length of the table.
    • rf

      private final RandomAccessFileOrArray rf
      The file in use.
    • fileName

      private final String fileName
      The file name.
    • includeCmap

      private final boolean includeCmap
    • includeExtras

      private final boolean includeExtras
    • locaShortTable

      private boolean locaShortTable
    • locaTable

      private int[] locaTable
    • glyphsUsed

      private final HashMap glyphsUsed
    • glyphsInList

      private final ArrayList glyphsInList
    • tableGlyphOffset

      private int tableGlyphOffset
    • newLocaTable

      private int[] newLocaTable
    • newLocaTableOut

      private byte[] newLocaTableOut
    • newGlyfTable

      private byte[] newGlyfTable
    • glyfTableRealSize

      private int glyfTableRealSize
    • locaTableRealSize

      private int locaTableRealSize
    • outFont

      private byte[] outFont
    • fontPtr

      private int fontPtr
    • directoryOffset

      private final int directoryOffset
  • Constructor Details

    • TrueTypeFontSubSet

      TrueTypeFontSubSet(String fileName, RandomAccessFileOrArray rf, HashMap glyphsUsed, int directoryOffset, boolean includeCmap, boolean includeExtras)
      Creates a new TrueTypeFontSubSet
      Parameters:
      fileName - the file name of the font
      glyphsUsed - the glyphs used
      directoryOffset - The offset from the start of the file to the table directory
      includeCmap - true if the table cmap is to be included in the generated font
  • Method Details