import org.apache.fop.apps.FOPException;
import org.apache.fop.apps.FOUserAgent;
-import org.apache.fop.fonts.FontInfo;
import org.apache.fop.render.intermediate.IFDocumentHandler;
import org.apache.fop.render.intermediate.IFException;
import org.apache.fop.render.intermediate.IFParser;
+import org.apache.fop.render.intermediate.IFUtil;
/**
* InputHandler for the intermediate format XML as input.
userAgent, outputFormat);
try {
documentHandler.setResult(new StreamResult(out));
- documentHandler.setDefaultFontInfo(new FontInfo());
+ IFUtil.setupFonts(documentHandler);
//Create IF parser
IFParser parser = new IFParser();
//TODO Ignored: state.getFontVariant()
//TODO Opportunity for font caching if font state is more heavily used
String fontKey = getFontInfo().getInternalFontKey(triplet);
+ if (fontKey == null) {
+ throw new IFException("Font not available: " + triplet, null);
+ }
int sizeMillipoints = state.getFontSize();
// This assumes that *all* CIDFonts use a /ToUnicode mapping