org.extex.font
Interface CoreFontFactory

All Superinterfaces:
ResourceFinder
All Known Subinterfaces:
FontFactory
All Known Implementing Classes:
FontFactoryImpl

public interface CoreFontFactory
extends ResourceFinder

This interface describes the features of a font factory needed by the core.

Version:
$Revision: 5563 $
Author:
Gerd Neugebauer, Michael Niedermair

Method Summary
 BackendFontManager createManager(java.util.List<java.lang.String> fontTypes)
          Create a manager for the back-end font.
 FontKey getFontKey(FontKey fontKey, FixedDimen size)
          Returns a font key for the font.
 FontKey getFontKey(java.lang.String fontName)
          Returns a font key for the font.
 FontKey getFontKey(java.lang.String fontName, FixedDimen size)
          Returns a font key for the font.
 FontKey getFontKey(java.lang.String fontName, FixedDimen size, java.util.Map<java.lang.String,?> map)
          Returns a font key for the font.
 FontKey getFontKey(java.lang.String fontName, FixedDimen size, java.util.Map<java.lang.String,?> map, java.util.List<java.lang.String> feature)
          Returns a font key for the font.
 ExtexFont getInstance(FontKey key)
          Return a new instance.
 
Methods inherited from interface org.extex.resource.ResourceFinder
enableTracing, findResource
 

Method Detail

createManager

BackendFontManager createManager(java.util.List<java.lang.String> fontTypes)
                                 throws ConfigurationException
Create a manager for the back-end font.

Parameters:
fontTypes - the font types, which the back-end can use. The order of the entries in the list determine the preference for the font format. This should be taken into account when several alternatives are possible.
Returns:
the new manager.
Throws:
ConfigurationException - from the configuration system.

getFontKey

FontKey getFontKey(FontKey fontKey,
                   FixedDimen size)
Returns a font key for the font.

Parameters:
fontKey - the key of the font.
size - the size of the font.
Returns:
the key for the font.

getFontKey

FontKey getFontKey(java.lang.String fontName)
Returns a font key for the font.

Parameters:
fontName - the name of the font.
Returns:
the key for the font.

getFontKey

FontKey getFontKey(java.lang.String fontName,
                   FixedDimen size)
Returns a font key for the font.

Parameters:
fontName - the name of the font.
size - the size of the font.
Returns:
the key for the font.

getFontKey

FontKey getFontKey(java.lang.String fontName,
                   FixedDimen size,
                   java.util.Map<java.lang.String,?> map)
Returns a font key for the font.

Parameters:
fontName - the name of the font.
size - the size of the font.
map - the map for the key.
Returns:
the key for the font.

getFontKey

FontKey getFontKey(java.lang.String fontName,
                   FixedDimen size,
                   java.util.Map<java.lang.String,?> map,
                   java.util.List<java.lang.String> feature)
Returns a font key for the font.

Parameters:
fontName - the name of the font.
size - the size of the font.
map - the map for the key.
feature - the list of features.
Returns:
the key for the font.

getInstance

ExtexFont getInstance(FontKey key)
                      throws FontException
Return a new instance. If the name is empty or null, then the NullFont is returned. If no font is found, then null is returned.

Parameters:
key - the fount key
Returns:
Returns the new font instance.
Throws:
ConfigurationException - from the resource finder.
FontException - if a font error occurred.