com.lowagie.text.pdf
Class CFFFont

java.lang.Object
  extended by com.lowagie.text.pdf.CFFFont
Direct Known Subclasses:
CFFFontSubset

public class CFFFont
extends java.lang.Object


Nested Class Summary
protected static class CFFFont.DictNumberItem
          A dictionary number on the list.
protected static class CFFFont.DictOffsetItem
          an unknown offset in a dictionary for the list.
protected  class CFFFont.Font
          TODO Changed from private to protected by Ygal&Oren
protected static class CFFFont.IndexBaseItem
           
protected static class CFFFont.IndexMarkerItem
           
protected static class CFFFont.IndexOffsetItem
          An index-offset item for the list.
protected static class CFFFont.Item
          List items for the linked list that builds the new CID font.
protected static class CFFFont.MarkerItem
          An offset-marker item for the list.
protected static class CFFFont.OffsetItem
           
protected static class CFFFont.RangeItem
          A range item.
protected static class CFFFont.StringItem
           
protected static class CFFFont.SubrMarkerItem
          TODO To change the template for this generated type comment go to Window - Preferences - Java - Code Generation - Code and Comments
protected static class CFFFont.UInt16Item
          A SID or Card16 item.
protected static class CFFFont.UInt24Item
          Card24 item.
protected static class CFFFont.UInt32Item
          Card32 item.
protected static class CFFFont.UInt8Item
          A Card8 item.
 
Field Summary
protected  int arg_count
           
protected  java.lang.Object[] args
           
protected  RandomAccessFileOrArray buf
          A random Access File or an array
protected  CFFFont.Font[] fonts
           
protected  int gsubrIndexOffset
           
protected  int[] gsubrOffsets
           
protected  java.lang.String key
           
protected  int nameIndexOffset
           
protected  int[] nameOffsets
           
protected  int stringIndexOffset
           
protected  int[] stringOffsets
           
protected  int topdictIndexOffset
           
protected  int[] topdictOffsets
           
 
Constructor Summary
CFFFont(RandomAccessFileOrArray inputbuffer)
           
 
Method Summary
 boolean exists(java.lang.String fontName)
           
 byte[] getCID(java.lang.String fontName)
          get a single CID font.
protected  void getDictItem()
           
protected  CFFFont.RangeItem getEntireIndexRange(int indexOffset)
          a utility that creates a range item for an entire index
 java.lang.String[] getNames()
           
 java.lang.String getString(char sid)
           
 boolean isCID(java.lang.String fontName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

key

protected java.lang.String key

args

protected java.lang.Object[] args

arg_count

protected int arg_count

buf

protected RandomAccessFileOrArray buf
A random Access File or an array


nameIndexOffset

protected int nameIndexOffset

topdictIndexOffset

protected int topdictIndexOffset

stringIndexOffset

protected int stringIndexOffset

gsubrIndexOffset

protected int gsubrIndexOffset

nameOffsets

protected int[] nameOffsets

topdictOffsets

protected int[] topdictOffsets

stringOffsets

protected int[] stringOffsets

gsubrOffsets

protected int[] gsubrOffsets

fonts

protected CFFFont.Font[] fonts
Constructor Detail

CFFFont

public CFFFont(RandomAccessFileOrArray inputbuffer)
Method Detail

getString

public java.lang.String getString(char sid)

getDictItem

protected void getDictItem()

getEntireIndexRange

protected CFFFont.RangeItem getEntireIndexRange(int indexOffset)
a utility that creates a range item for an entire index

Parameters:
indexOffset - where the index is
Returns:
a range item representing the entire index

getCID

public byte[] getCID(java.lang.String fontName)
get a single CID font. The PDF architecture (1.4) supports 16-bit strings only with CID CFF fonts, not in Type-1 CFF fonts, so we convert the font to CID if it is in the Type-1 format. Two other tasks that we need to do are to select only a single font from the CFF package (this again is a PDF restriction) and to subset the CharStrings glyph description.


isCID

public boolean isCID(java.lang.String fontName)

exists

public boolean exists(java.lang.String fontName)

getNames

public java.lang.String[] getNames()


iText 2.1.7