|
fop 0.93 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.xml.sax.helpers.DefaultHandler
org.apache.fop.fonts.FontReader
Class for reading a metric.xml file and creating a font object. Typical usage:
FontReader reader = new FontReader(); reader.setFontEmbedPath( ); reader.useKerning(true); Font f = reader.getFont();
| Constructor Summary | |
FontReader(org.xml.sax.InputSource source)
Construct a FontReader object from a path to a metric.xml file and read metric data |
|
| Method Summary | |
void |
characters(char[] ch,
int start,
int length)
|
void |
endElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName)
|
Typeface |
getFont()
Get the generated font object |
void |
setDocumentLocator(org.xml.sax.Locator locator)
|
void |
setFontEmbedPath(java.lang.String path)
Sets the path to embed a font. |
void |
setKerningEnabled(boolean enabled)
Enable/disable use of kerning for the font |
void |
setResolver(FontResolver resolver)
Sets the font resolver. |
void |
startDocument()
|
void |
startElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes attributes)
|
| Methods inherited from class org.xml.sax.helpers.DefaultHandler |
endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startPrefixMapping, unparsedEntityDecl, warning |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public FontReader(org.xml.sax.InputSource source)
throws FOPException
source - Source of the font metric file
FOPException - if loading the font fails| Method Detail |
public void setFontEmbedPath(java.lang.String path)
path - URI for the embeddable filepublic void setKerningEnabled(boolean enabled)
enabled - true to enable kerning, false to disablepublic void setResolver(FontResolver resolver)
resolver - the font resolverpublic Typeface getFont()
public void startDocument()
ContentHandler.startDocument()public void setDocumentLocator(org.xml.sax.Locator locator)
ContentHandler.setDocumentLocator(Locator)
public void startElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes attributes)
throws org.xml.sax.SAXException
org.xml.sax.SAXExceptionContentHandler.startElement(String, String, String, Attributes)
public void endElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName)
throws org.xml.sax.SAXException
org.xml.sax.SAXExceptionContentHandler.endElement(String, String, String)
public void characters(char[] ch,
int start,
int length)
ContentHandler.characters(char[], int, int)
|
fop 0.93 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||