public class Type1Font extends OutlineFont
| Constructor and Description |
|---|
Type1Font(String baseName,
PDFObject src,
PDFFontDescriptor descriptor)
create a new Type1Font based on a font data stream and an encoding.
|
| Modifier and Type | Method and Description |
|---|---|
protected GeneralPath |
getOutline(char src,
float width)
Get a glyph outline by character code
Note this method must always return an outline
|
protected GeneralPath |
getOutline(String name,
float width)
Get a glyph outline by name
|
float |
getWidth(char code,
String name)
Get the width of a given character
This method is overridden to work if the width array hasn't been
populated (as for one of the 14 base fonts)
|
protected void |
parseFont(byte[] font,
int start,
int len)
Read a font from it's data, start position and length
|
getCharCount, getDefaultWidth, getFirstChar, getGlyph, getLastCharequals, getBaseFont, getCachedGlyph, getDescriptor, getEncoding, getFont, getGlyphs, getSubtype, getUnicodeMap, hashCode, setBaseFont, setDescriptor, setEncoding, setSubtype, setUnicodeMap, toStringpublic Type1Font(String baseName, PDFObject src, PDFFontDescriptor descriptor) throws IOException
baseName - the postscript name of this fontsrc - the Font object as a stream with a dictionarydescriptor - the descriptor for this fontIOExceptionprotected void parseFont(byte[] font,
int start,
int len)
public float getWidth(char code,
String name)
getWidth in class OutlineFontprotected GeneralPath getOutline(String name, float width)
getOutline in class OutlineFontname - the name of the desired glyphprotected GeneralPath getOutline(char src, float width)
getOutline in class OutlineFontsrc - the character code of the desired glyphCopyright © 2024. All rights reserved.