TrueTypeFont

Overview

TrueTypeFont is a class in Aspose.Pdf FOSS for Java. Inherits from: PdfFont.

TrueType font (/Subtype /TrueType) - ISO 32000-1:2008, 9.6.3.

Properties

NameTypeAccessDescription
trueTypeReaderTrueTypeReaderReadReturns the TrueTypeReader if the font program was loaded.
baseFontStringReadReturns the base font name (/BaseFont).
encodingFontEncodingReadReturns the font encoding.
toUnicodeToUnicodeCMapReadReturns the ToUnicode CMap.
fontDescriptorFontDescriptorReadReturns the font descriptor.
compositebooleanReadReturns {@code true} when this is a Type0 composite font whose
content-stream encoding uses multi-byte character codes (e.g.
fontMetricsFontMetricsReadReturns the font metrics.
fontDictionaryCOSDictionaryReadReturns the underlying font dictionary.

Methods

SignatureDescription
TrueTypeFont(fontDict: COSDictionary, parser: PDFParser)Creates a TrueTypeFont from a font dictionary.
decode(charCodes: byte[])String
getWidth(charCode: int)double
getTrueTypeReader()TrueTypeReaderReturns the TrueTypeReader if the font program was loaded.
getBaseFont()StringReturns the base font name (/BaseFont).
getEncoding()FontEncodingReturns the font encoding.
getToUnicode()ToUnicodeCMapReturns the ToUnicode CMap.
getFontDescriptor()FontDescriptorReturns the font descriptor.
isComposite()booleanReturns {@code true} when this is a Type0 composite font whose
content-stream encoding uses multi-byte character codes (e.g.
getFontMetrics()FontMetricsReturns the font metrics.
getFontDictionary()COSDictionaryReturns the underlying font dictionary.
fromDictionary(fontDict: COSDictionary, parser: PDFParser)PdfFontCreates the appropriate PdfFont subclass from a font dictionary.

See Also