APIdia Launch Partner
Top Inners Fields Constructors Methods
sun.font

public Class Type1Font

extends FileFont
Class Inheritance
Imports
java.awt.FontFormatException, java.io.FileNotFoundException, .IOException, .RandomAccessFile, java.lang.ref.WeakReference, java.nio.BufferUnderflowException, .ByteBuffer, .ByteOrder, java.nio.channels.ClosedChannelException, .FileChannel, java.util.HashMap, .HashSet, sun.java2d.Disposer, .DisposerRecord

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
pack-priv WeakReference<ByteBuffer>
private static final int
private String
private static final int
private static final int
private static final HashMap<String, String>
private static final HashSet<String>
Inherited from sun.font.FileFont:
fileSizeglyphToCharMapnativeFontsscaleruseJavaRasterizer

Constructor Summary

AccessConstructor and Description
public
Type1Font(String
- Platform identifier of the font. Typically file name.
platname
,
Object
- Native names - typically XLFDs on Unix.
nativeNames
)

Constructs a Type1 Font.

public
Type1Font(String platname, Object nativeNames, boolean createdCopy)

- does basic verification of the file - reads the names (full, family).

Method Summary

Modifier and TypeMethod and Description
protected void
close()

Implements abstract sun.font.FileFont.close.

private String
private String
expandName(String s, boolean tryExpandAbbreviations)

private String
private synchronized ByteBuffer
public int
public int
getGlyphCode(char charCode)

pack-priv CharToGlyphMapper
getMapper()

Implements abstract sun.font.Font2D.getMapper.

public int
public int
public String
protected synchronized FontScaler
getScaler()

Implements abstract sun.font.FileFont.getScaler.

private String
private String
private void
private boolean
private int
private int
private String
private String
public synchronized ByteBuffer
readBlock(int offset, int length)

Implements abstract sun.font.FileFont.readBlock.

pack-priv void
private byte
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

private void
private void
private void
Inherited from sun.font.FileFont:
canDoStylecreateStrikederegisterFontAndClearStrikeCachegetFontMetricsgetGlyphAdvancegetGlyphImagegetGlyphMetricsgetGlyphOutlinegetGlyphOutlineBoundsgetGlyphVectorOutlinegetPublicFileNamegetUnitsPerEmsetFileToRemove

Field Detail

bufferRefback to summary
pack-priv WeakReference<ByteBuffer> bufferRef
PSEOFTOKENback to summary
private static final int PSEOFTOKEN
psNameback to summary
private String psName
PSNAMETOKENback to summary
private static final int PSNAMETOKEN
PSSTRINGTOKENback to summary
private static final int PSSTRINGTOKEN
styleAbbreviationsMappingback to summary
private static final HashMap<String, String> styleAbbreviationsMapping
styleNameTokesback to summary
private static final HashSet<String> styleNameTokes

Constructor Detail

Type1Fontback to summary
public Type1Font(String platname, Object nativeNames) throws FontFormatException

Constructs a Type1 Font.

Parameters
platname:String

- Platform identifier of the font. Typically file name.

nativeNames:Object

- Native names - typically XLFDs on Unix.

Type1Fontback to summary
public Type1Font(String platname, Object nativeNames, boolean createdCopy) throws FontFormatException

- does basic verification of the file - reads the names (full, family). - determines the style of the font.

Exceptions
FontFormatException:
if the font can't be opened or fails verification, or there's no usable cmap

Method Detail

closeback to summary
protected void close()

Implements abstract sun.font.FileFont.close.

expandAbbreviationback to summary
private String expandAbbreviation(String abbr)
expandNameback to summary
private String expandName(String s, boolean tryExpandAbbreviations)
fullName2FamilyNameback to summary
private String fullName2FamilyName(String name)
getBufferback to summary
private synchronized ByteBuffer getBuffer() throws FontFormatException
getFileSizeback to summary
public int getFileSize()
getGlyphCodeback to summary
public int getGlyphCode(char charCode)
getMapperback to summary
pack-priv CharToGlyphMapper getMapper()

Implements abstract sun.font.Font2D.getMapper.

getMissingGlyphCodeback to summary
public int getMissingGlyphCode()

Overrides sun.font.Font2D.getMissingGlyphCode.

getNumGlyphsback to summary
public int getNumGlyphs()

Overrides sun.font.Font2D.getNumGlyphs.

getPostscriptNameback to summary
public String getPostscriptName()

Overrides sun.font.Font2D.getPostscriptName.

getScalerback to summary
protected synchronized FontScaler getScaler()

Implements abstract sun.font.FileFont.getScaler.

getSimpleTokenback to summary
private String getSimpleToken(ByteBuffer bb)
getStringback to summary
private String getString(ByteBuffer bb)
initNamesback to summary
private void initNames(ByteBuffer bb) throws FontFormatException
isStyleTokenback to summary
private boolean isStyleToken(String token)
nextCapitalLetterback to summary
private int nextCapitalLetter(String s, int off)
nextTokenTypeback to summary
private int nextTokenType(ByteBuffer bb)
psName2FamilyNameback to summary
private String psName2FamilyName(String name)
psName2FullNameback to summary
private String psName2FullName(String name)
readBlockback to summary
public synchronized ByteBuffer readBlock(int offset, int length)

Implements abstract sun.font.FileFont.readBlock.

readFileback to summary
pack-priv void readFile(ByteBuffer buffer)
skipback to summary
private byte skip(ByteBuffer bb)
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

verifyback to summary
private void verify() throws FontFormatException
verifyPFAback to summary
private void verifyPFA(ByteBuffer bb) throws FontFormatException
verifyPFBback to summary
private void verifyPFB(ByteBuffer bb) throws FontFormatException
sun.font back to summary

private Class Type1Font.T1DisposerRecord

extends Object
implements DisposerRecord
Class Inheritance
All Implemented Interfaces
sun.java2d.DisposerRecord

Field Summary

Modifier and TypeField and Description
pack-priv String

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public synchronized void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

fileNameback to summary
pack-priv String fileName

Constructor Detail

T1DisposerRecordback to summary
pack-priv T1DisposerRecord(String name)

Method Detail

disposeback to summary
public synchronized void dispose()

Implements sun.java2d.DisposerRecord.dispose.