Class DefaultFontConfigurator
java.lang.Object
org.apache.fop.fonts.DefaultFontConfigurator
- All Implemented Interfaces:
FontConfigurator<EmbedFontInfo>
The default configurator for fonts. This configurator can configure the more generic fonts used
by the renderers i.e. TTF, Type1 etc...
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final FontManagerprivate final FontEventListenerprotected static final org.apache.commons.logging.Loglogger instanceprivate final InternalResourceResolverprivate final boolean -
Constructor Summary
ConstructorsConstructorDescriptionDefaultFontConfigurator(FontManager fontManager, FontEventListener listener, boolean strict) Main constructor -
Method Summary
Modifier and TypeMethodDescriptionprivate voidaddDirectories(DefaultFontConfig fontInfoConfig, FontAdder fontAdder, List<EmbedFontInfo> fontInfoList) private voidaddFonts(DefaultFontConfig fontInfoConfig, FontCache fontCache, List<EmbedFontInfo> fontInfoList) configure(FontConfig fontInfoConfig) Initializes font info settings from the user configurationprivate EmbedFontInfogetFontInfo(DefaultFontConfig.Font font, FontCache fontCache)
-
Field Details
-
log
protected static final org.apache.commons.logging.Log loglogger instance -
fontManager
-
resourceResolver
-
listener
-
strict
private final boolean strict
-
-
Constructor Details
-
DefaultFontConfigurator
Main constructor- Parameters:
fontManager- the font managerlistener- the font event listenerstrict- true if an Exception should be thrown if an error is found.
-
-
Method Details
-
configure
Initializes font info settings from the user configuration- Specified by:
configurein interfaceFontConfigurator<EmbedFontInfo>- Returns:
- a font info list
- Throws:
FOPException- if an exception occurs while processing the configuration
-
addDirectories
private void addDirectories(DefaultFontConfig fontInfoConfig, FontAdder fontAdder, List<EmbedFontInfo> fontInfoList) throws FOPException - Throws:
FOPException
-
addFonts
private void addFonts(DefaultFontConfig fontInfoConfig, FontCache fontCache, List<EmbedFontInfo> fontInfoList) throws FOPException, URISyntaxException - Throws:
FOPExceptionURISyntaxException
-
getFontInfo
private EmbedFontInfo getFontInfo(DefaultFontConfig.Font font, FontCache fontCache) throws FOPException, URISyntaxException - Throws:
FOPExceptionURISyntaxException
-