public interface FontPdf extends FontOutput
Modifier and Type | Method and Description |
---|---|
int |
getFirstIndex()
Convenience method equivalent to
getFontUse().getEncoding().getFirstIndex() . |
int |
getFlags()
Returns the Flags value for this font, used in a PDF Font Descriptor, as
defined in the PDF Reference, Second Edition, Section 5.7, and, more
specifically, in Section 5.7.1.
|
int[] |
getFontBoundingBox()
Returns the FontBBox value for this font, used in a PDF Font Descriptor,
as defined in the PDF Reference, Second Edition, Section 5.7.
|
java.lang.String |
getItalicAngleFormatted()
Returns a compactly formatted version of the ItalicAngle value for this
font, expressed in degrees counterclockwise from vertical.
|
int |
getLastIndex()
Convenience method equivalent to
getFontUse().getEncoding().getFirstIndex() . |
java.lang.String |
getPdfFontFileStreamAdditional()
Returns the "Additional entries in a FontFile stream dictionary" that is
documented in the PDF Reference, Second Edition, Section 5.8, especially
Table 5.22.
|
java.lang.String |
getToUnicodeBf()
Return the BF Entries needed to write this
FontUse 's ToUnicode
CMap. |
short[] |
getWidths()
Returns an array containing the widths of all glyphs in the font that
can be encoded by the
FontUse instance. |
java.lang.String |
textToPdf(java.lang.CharSequence theString,
FontOptions fontOptions,
Orthography orthography)
Converts a String to the content that should be written into a PDF to show that String.
|
getContents, getFontUse
short[] getWidths()
FontUse
instance.FontUse
instance.
Element 0 contains the width for the first encodable glyph index (see
Encoding.getFirstIndex()
).
The last element contains the width for the last encodable glyph index
(see Encoding.getLastIndex()
).
Each element contains the width for the encodable glyph index that is
equal to the element index + Encoding.getFirstIndex()
.
For fonts that have been subsetted, only the characters that are
included in the subset are returned.int getFirstIndex()
getFontUse().getEncoding().getFirstIndex()
.
This is the glyph index for the first item in the array returned by
getWidths()
.
This is needed when embedding some types of fonts in a PDF file.int getLastIndex()
getFontUse().getEncoding().getFirstIndex()
.
This is the glyph index for the last item in the array returned by
getWidths()
.
This is needed when embedding some types of fonts in a PDF file.java.lang.String getPdfFontFileStreamAdditional()
Font.isEmbeddable()
is false.int[] getFontBoundingBox()
int getFlags()
java.lang.String getItalicAngleFormatted()
java.lang.String getToUnicodeBf()
FontUse
's ToUnicode
CMap.FontUse
's
ToUnicode CMap.
For fonts that have been subsetted, the entries only apply to the
subset.java.lang.String textToPdf(java.lang.CharSequence theString, FontOptions fontOptions, Orthography orthography)
theString
- The input String, that is, the text that needs to be shown in the PDF.fontOptions
- The font options, such as ligatures and small-caps that should be used when computing the
glyphs for this word.orthography
- The orthography that should be used when applying font features like subsitutions.This documentation was created 2017-01-24 at 21:26 GMT by The aXSL Group and may be freely copied. See license for details.