public class PDFFontSetImpl extends Object implements PDFFontSet
ARABIC, HEBREW, THAI| Constructor and Description |
|---|
PDFFontSetImpl() |
PDFFontSetImpl(FontResolutionPriority priority)
Default constructor that provides no fonts.
|
PDFFontSetImpl(PDFFontSetImpl original) |
| Modifier and Type | Method and Description |
|---|---|
void |
addFallbackFont(Locale locale,
Font font)
Add a given
Font to the
PDFFontSet for use as a fallback font for the given locale. |
void |
addFallbackFont(Locale locale,
Font[] fonts)
Add an array of
Font objects to the
PDFFontSet for use as a fallback font for the given locale. |
void |
addFont(Font font)
Add a given
Font to the
PDFFontSet for use in font lookup. |
void |
addFont(Font[] fonts)
Add an array of
Font objects to the
PDFFontSet for use in font lookup. |
void |
addFont(Font[] fonts,
Platform platForm,
ULocale locale)
Add an array of
Font objects to the
PDFFontSet for use in font lookup. |
void |
addFont(Font font,
Platform platForm,
ULocale locale)
Add a given
Font to the
PDFFontSet for use in font lookup. |
void |
addFont(Font font,
PostscriptFontDescription[] psDescriptions,
CSS20FontDescription[] cssDescriptions)
Add a given
Font to the
PDFFontSet. |
CSS20FontSet |
getCSS20FontSet()
Get the CSS20 fonts.
|
Font |
getFallbackFont(Locale locale)
Gets the preferred fallback font for locale supplied
|
FallbackFontSet |
getFallbackFontSet()
Get the fallback fonts.
|
Font |
getPSFont(PostscriptFontDescription fontDescription,
Locale locale,
boolean substitute)
Get the PS fonts.
|
Font |
getPSFont(String fontName,
Locale locale,
boolean substitute) |
PSNameResolver |
getPSFontSet()
Get the PS fonts.
|
boolean |
hasRootFallback()
Returns true if there is a "final fallback" font installed in ULocale.ROOT.
|
void |
setGenericFontFamilyName(CSS20GenericFontFamily family,
String[] replacements)
An array of font family names to use as replacements for the generic CSS font family names.
|
void |
setIgnoreFontLoadingErrors(boolean ignoreFontLoadingErrors)
Sets if any error while adding font to fontset should be ignored
|
void |
setResolutionPriority(FontResolutionPriority priority) |
String |
toString()
A debugging string containing information about the contents
of the
PDFFontSetImpl instance. |
public PDFFontSetImpl()
throws PDFFontException
PDFFontExceptionpublic PDFFontSetImpl(FontResolutionPriority priority) throws PDFFontException
PDFFontExceptionpublic PDFFontSetImpl(PDFFontSetImpl original) throws PDFFontException
PDFFontExceptionpublic boolean hasRootFallback()
throws PDFFontException
PDFFontSethasRootFallback in interface PDFFontSetPDFFontExceptionpublic void addFont(Font font, Platform platForm, ULocale locale) throws PDFFontException
PDFFontSetFont to the
PDFFontSet for use in font lookup.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.
The font shall be added for locale and platform specified by clients. If either of the platform and
locale are passed as null then defaults shall be used.addFont in interface PDFFontSetfont - a non-null valid Font objectPDFFontExceptionpublic void addFont(Font font, PostscriptFontDescription[] psDescriptions, CSS20FontDescription[] cssDescriptions) throws PDFFontException
PDFFontSetFont to the
PDFFontSet. The provided PostScript and CSS font descriptions
will be used during font lookup. Either array of descriptions can be null.
If the Font's native font descriptions
are also desired, both this API and other addFont variants
can be called with the same Font instance.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.addFont in interface PDFFontSetPDFFontExceptionpublic void addFont(Font[] fonts, Platform platForm, ULocale locale) throws PDFFontException
PDFFontSetFont objects to the
PDFFontSet for use in font lookup.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.
The font shall be added for locale and platform specified by clients. If either of the platform and
locale are passed as null then defaults shall be used.addFont in interface PDFFontSetfonts - a non-null array of non-null valid Font objectsPDFFontExceptionpublic void addFallbackFont(Locale locale, Font font) throws PDFFontException
PDFFontSetFont to the
PDFFontSet for use as a fallback font for the given locale.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.addFallbackFont in interface PDFFontSetlocale - the locale for which this fallback font should be usedfont - a non-null valid Font objectPDFFontExceptionpublic void addFallbackFont(Locale locale, Font[] fonts) throws PDFFontException
PDFFontSetFont objects to the
PDFFontSet for use as a fallback font for the given locale.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.addFallbackFont in interface PDFFontSetlocale - the locale for which this fallback font should be usedfonts - a non-null array of non-null valid Font objectsPDFFontExceptionpublic void setGenericFontFamilyName(CSS20GenericFontFamily family, String[] replacements) throws PDFFontException
PDFFontSetsetGenericFontFamilyName in interface PDFFontSetreplacements - a non-null array of non-null valid String objectsPDFFontExceptionCSS20GenericFontFamilypublic CSS20FontSet getCSS20FontSet() throws PDFFontException
PDFFontExceptionpublic PSNameResolver getPSFontSet() throws PDFFontException
PDFFontExceptionpublic FallbackFontSet getFallbackFontSet() throws PDFFontException
getFallbackFontSet in interface PDFFontSetPDFFontExceptionpublic Font getPSFont(PostscriptFontDescription fontDescription, Locale locale, boolean substitute) throws PDFFontException
substitute - If true and the exact fontDescription is not found, a fallback font can be returned.PDFFontExceptionpublic Font getFallbackFont(Locale locale)
locale - localepublic Font getPSFont(String fontName, Locale locale, boolean substitute) throws PDFFontException
PDFFontExceptionpublic void setResolutionPriority(FontResolutionPriority priority)
public String toString()
PDFFontSetImpl instance.public void addFont(Font font) throws PDFFontException
PDFFontSetFont to the
PDFFontSet for use in font lookup.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.
The font shall be added for default locale available and windows platform. If clients want to specify
locale and platform then they should call PDFFontSet.addFont(Font, Platform, ULocale).addFont in interface PDFFontSetfont - a non-null valid Font objectPDFFontExceptionpublic void addFont(Font[] fonts) throws PDFFontException
PDFFontSetFont objects to the
PDFFontSet for use in font lookup.
There is an inherent priority ordering based on the order that Font
objects are added with earlier added fonts having higher priority.
These fonts shall be added for default locale available and windows platform. If clients want to specify
locale and platform then they should call PDFFontSet.addFont(Font[], Platform, ULocale).addFont in interface PDFFontSetfonts - a non-null array of non-null valid Font objectsPDFFontExceptionpublic void setIgnoreFontLoadingErrors(boolean ignoreFontLoadingErrors)
PDFFontSetsetIgnoreFontLoadingErrors in interface PDFFontSetCopyright © 2010 - 2020 Adobe. All Rights Reserved