public abstract class PDCIDFont extends PDSimpleFont
cmap, cmapObjects, font, fontMatrix, resourceRootCMAP, toUnicodeCmap| Constructor and Description | 
|---|
| PDCIDFont()Constructor. | 
| PDCIDFont(COSDictionary fontDictionary)Constructor. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | clear()Calling this will release all cached information. | 
| protected void | determineEncoding()Determines the encoding for the font. | 
| String | encode(byte[] c,
      int offset,
      int length)This will perform the encoding of a character if needed. | 
| float | getAverageFontWidth()This will get the average font width for all characters. | 
| long | getDefaultWidth()This will get the default width. | 
| PDRectangle | getFontBoundingBox()This will get the fonts bouding box. | 
| float | getFontHeight(byte[] c,
             int offset,
             int length)This will get the font height for a character. | 
| float | getFontWidth(byte[] c,
            int offset,
            int length)This will get the font width for a character. | 
| float | getFontWidth(int charCode)Determines the width of the given character. | 
| void | setDefaultWidth(long dw)This will set the default width for the glyphs of this font. | 
drawString, getawtFont, getSpaceWidth, getToUnicode, isFontSubstituted, setIsFontSubstituted, setToUnicode, writeFontclearResources, cmapEncoding, drawString, encodeToCID, equals, getAFM, getAverageFontWidthFromAFMFile, getBaseFont, getCodeFromArray, getCOSObject, getEncoding, getFirstChar, getFontDescriptor, getFontEncoding, getFontMatrix, getFontWidthFromAFMFile, getLastChar, getStringFromArray, getStringWidth, getSubType, getToUnicodeCMap, getType, getWidths, hashCode, hasToUnicode, isSymbolicFont, isType0Font, isType1Font, isType3Font, parseCmap, setBaseFont, setEncoding, setFirstChar, setFontDescriptor, setFontEncoding, setHasToUnicode, setLastChar, setWidthspublic PDCIDFont()
public PDCIDFont(COSDictionary fontDictionary)
fontDictionary - The font dictionary according to the PDF specification.public PDRectangle getFontBoundingBox() throws IOException
getFontBoundingBox in class PDSimpleFontIOException - If there is an error getting the font bounding box.public long getDefaultWidth()
public void setDefaultWidth(long dw)
dw - The default width.public float getFontWidth(byte[] c,
                 int offset,
                 int length)
                   throws IOException
getFontWidth in class PDSimpleFontc - The character code to get the width for.offset - The offset into the array.length - The length of the data.IOException - If an error occurs while parsing.public float getFontHeight(byte[] c,
                  int offset,
                  int length)
                    throws IOException
getFontHeight in class PDSimpleFontc - The character code to get the height for.offset - The offset into the array.length - The length of the data.IOException - If an error occurs while parsing.public float getAverageFontWidth()
                          throws IOException
getAverageFontWidth in class PDSimpleFontIOException - If an error occurs while parsing.public float getFontWidth(int charCode)
getFontWidth in class PDFontcharCode - the code of the given characterprotected void determineEncoding()
PDSimpleFontdetermineEncoding in class PDSimpleFontpublic String encode(byte[] c, int offset, int length) throws IOException
PDFontencode in class PDFontc - The character to encode.offset - The offset into the array to get the datalength - The number of bytes to read.IOException - If there is an error during the encoding.Copyright © 2002–2016 The Apache Software Foundation. All rights reserved.