Author: jeremias
Date: Mon Feb 23 13:38:48 2009
New Revision: 747015
URL: http://svn.apache.org/viewvc?rev=747015&view=rev
Log:
Tied RendererFactory.setRendererPreferred(boolean) setting into the FOP
configuration (incl. documentation).
Modified:
xmlgraphics/fop/trunk/src/documentation/content/xdocs/trunk/configuration.xml
xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FopFactoryConfigurator.java
Modified:
xmlgraphics/fop/trunk/src/documentation/content/xdocs/trunk/configuration.xml
URL:
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/documentation/content/xdocs/trunk/configuration.xml?rev=747015&r1=747014&r2=747015&view=diff
==============================================================================
---
xmlgraphics/fop/trunk/src/documentation/content/xdocs/trunk/configuration.xml
(original)
+++
xmlgraphics/fop/trunk/src/documentation/content/xdocs/trunk/configuration.xml
Mon Feb 23 13:38:48 2009
@@ -152,6 +152,18 @@
<td>"height" 11 inches, "width" 8.26 inches</td>
</tr>
<tr>
+ <td>prefer-renderer</td>
+ <td>boolean (true, false)</td>
+ <td>
+ By default, FOP prefers the newer output implementations based on the
+ <code>IFDocumentHandler</code> interface. If no such implementation
can be found for
+ a given MIME type, it looks for an implementation of the
<code>Renderer</code> interface.
+ If necessary, you can invert the lookup order to prefer the Renderer
variant over the
+ IFDocumentHandler variant by setting this value to true.
+ </td>
+ <td>false</td>
+ </tr>
+ <tr>
<td>use-cache</td>
<td>boolean (true, false)</td>
<td>All fonts information that has been gathered as a result of
"directory"
Modified:
xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FopFactoryConfigurator.java
URL:
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FopFactoryConfigurator.java?rev=747015&r1=747014&r2=747015&view=diff
==============================================================================
---
xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FopFactoryConfigurator.java
(original)
+++
xmlgraphics/fop/trunk/src/java/org/apache/fop/apps/FopFactoryConfigurator.java
Mon Feb 23 13:38:48 2009
@@ -61,6 +61,8 @@
/** Defines the default target resolution (72dpi) for FOP */
public static final float DEFAULT_TARGET_RESOLUTION = 72.0f; //dpi
+ private static final String PREFER_RENDERER = "prefer-renderer";
+
/** logger instance */
private final Log log = LogFactory.getLog(FopFactoryConfigurator.class);
@@ -173,6 +175,16 @@
}
}
+ // prefer Renderer over IFDocumentHandler
+ if (cfg.getChild(PREFER_RENDERER, false) != null) {
+ try {
+ factory.getRendererFactory().setRendererPreferred(
+ cfg.getChild(PREFER_RENDERER).getValueAsBoolean());
+ } catch (ConfigurationException e) {
+ LogUtil.handleException(log, e, strict);
+ }
+ }
+
// configure font manager
FontManager fontManager = factory.getFontManager();
FontManagerConfigurator fontManagerConfigurator = new
FontManagerConfigurator(cfg);
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]