public class CFFDataReader
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
class |
CFFDataReader.CFFIndexData
An object used to hold index data from the CFF data
|
class |
CFFDataReader.CFFSubTable
Parent class which provides the ability to retrieve byte data from
a sub-table.
|
class |
CFFDataReader.CustomEncoding |
static class |
CFFDataReader.DICTEntry
A class containing data for a dictionary entry
|
class |
CFFDataReader.FDSelect |
class |
CFFDataReader.FontDict |
class |
CFFDataReader.Format0Encoding |
class |
CFFDataReader.Format0FDSelect |
class |
CFFDataReader.Format1Encoding |
class |
CFFDataReader.Format3FDSelect |
Constructor and Description |
---|
CFFDataReader() |
CFFDataReader(byte[] cffDataArray)
Constructor for the CFF data reader which accepts the CFF byte data
as an argument.
|
CFFDataReader(FontFileReader fontFile)
Constructor for the CFF data reader which accepts a FontFileReader object
which points to the original font file as an argument.
|
Modifier and Type | Method and Description |
---|---|
org.apache.fontbox.cff.CFFDataInput |
getCFFData() |
CFFDataReader.CFFIndexData |
getCharStringIndex() |
CFFDataReader.CustomEncoding |
getEncoding() |
java.util.List<CFFDataReader.FontDict> |
getFDFonts() |
CFFDataReader.FDSelect |
getFDSelect() |
CFFDataReader.CFFIndexData |
getGlobalIndexSubr() |
byte[] |
getHeader() |
CFFDataReader.CFFIndexData |
getLocalIndexSubr() |
org.apache.fontbox.cff.CFFDataInput |
getLocalSubrsForGlyph(int glyph) |
CFFDataReader.CFFIndexData |
getNameIndex() |
java.util.Map<java.lang.String,CFFDataReader.DICTEntry> |
getPrivateDict(CFFDataReader.DICTEntry privateEntry) |
byte[] |
getPrivateDictBytes(CFFDataReader.DICTEntry privateEntry) |
int |
getSIDFromGID(int charsetOffset,
int gid)
Retrieves the SID for the given GID object
|
CFFDataReader.CFFIndexData |
getStringIndex() |
java.util.LinkedHashMap<java.lang.String,CFFDataReader.DICTEntry> |
getTopDictEntries() |
CFFDataReader.CFFIndexData |
getTopDictIndex() |
java.util.LinkedHashMap<java.lang.String,CFFDataReader.DICTEntry> |
parseDictData(byte[] dictData)
Parses the dictionary data and returns a map of objects for each entry
|
CFFDataReader.CFFIndexData |
readCharStringIndex()
Parses the char string index from the CFF byte data
|
CFFDataReader.CFFIndexData |
readIndex(org.apache.fontbox.cff.CFFDataInput input)
Reads an index from the current position of the CFFDataInput object
|
CFFDataReader.CFFIndexData |
readIndex(int offset)
Reads a CFF index object are the specified offset position
|
public CFFDataReader()
public CFFDataReader(byte[] cffDataArray) throws java.io.IOException
cffDataArray
- A byte array which holds the CFF datajava.io.IOException
public CFFDataReader(FontFileReader fontFile) throws java.io.IOException
fontFile
- The font file as represented by a FontFileReader objectjava.io.IOException
public java.util.Map<java.lang.String,CFFDataReader.DICTEntry> getPrivateDict(CFFDataReader.DICTEntry privateEntry) throws java.io.IOException
java.io.IOException
public byte[] getPrivateDictBytes(CFFDataReader.DICTEntry privateEntry) throws java.io.IOException
java.io.IOException
public java.util.LinkedHashMap<java.lang.String,CFFDataReader.DICTEntry> parseDictData(byte[] dictData) throws java.io.IOException
dictData
- The data for the dictionary datajava.io.IOException
- Throws an IO Exception if an error occurspublic CFFDataReader.CFFIndexData readIndex(int offset) throws java.io.IOException
offset
- The position of the index object to readjava.io.IOException
- Throws an IO Exception if an error occurspublic CFFDataReader.CFFIndexData readIndex(org.apache.fontbox.cff.CFFDataInput input) throws java.io.IOException
input
- The object holding the CFF byte datajava.io.IOException
- Throws an IO Exception if an error occurspublic int getSIDFromGID(int charsetOffset, int gid) throws java.io.IOException
charsetOffset
- The offset of the charset dataGID
- The GID for which to retrieve the SIDjava.io.IOException
public byte[] getHeader()
public CFFDataReader.CFFIndexData getNameIndex()
public CFFDataReader.CFFIndexData getTopDictIndex()
public java.util.LinkedHashMap<java.lang.String,CFFDataReader.DICTEntry> getTopDictEntries()
public CFFDataReader.CFFIndexData getStringIndex()
public CFFDataReader.CFFIndexData getGlobalIndexSubr()
public CFFDataReader.CFFIndexData getLocalIndexSubr()
public CFFDataReader.CFFIndexData getCharStringIndex()
public org.apache.fontbox.cff.CFFDataInput getCFFData()
public CFFDataReader.CustomEncoding getEncoding()
public CFFDataReader.FDSelect getFDSelect()
public java.util.List<CFFDataReader.FontDict> getFDFonts()
public org.apache.fontbox.cff.CFFDataInput getLocalSubrsForGlyph(int glyph) throws java.io.IOException
java.io.IOException
public CFFDataReader.CFFIndexData readCharStringIndex() throws java.io.IOException
offset
- The offset to the char string indexjava.io.IOException
- Throws an IO Exception if an error occursCopyright 1999-2017 The Apache Software Foundation. All Rights Reserved.