aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/render
diff options
context:
space:
mode:
authorJeremias Maerki <jeremias@apache.org>2009-01-05 07:59:39 +0000
committerJeremias Maerki <jeremias@apache.org>2009-01-05 07:59:39 +0000
commitc0028134f8261116cbfd1a263f8e28456a81522e (patch)
tree8c076130ae9be0cc0871132b5fb2348dbedc05ff /src/java/org/apache/fop/render
parent011fd36fcef0003a63e9dc8da3233fd18c7889fb (diff)
parent68dd1750c65ec6ce5475f2f12ea63f6495a708ad (diff)
downloadxmlgraphics-fop-c0028134f8261116cbfd1a263f8e28456a81522e.tar.gz
xmlgraphics-fop-c0028134f8261116cbfd1a263f8e28456a81522e.zip
Merge from Trunk revisions 728026 - 731479.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AreaTreeNewDesign@731480 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/render')
-rw-r--r--src/java/org/apache/fop/render/PrintRendererConfigurator.java4
-rw-r--r--src/java/org/apache/fop/render/java2d/ConfiguredFontCollection.java3
2 files changed, 6 insertions, 1 deletions
diff --git a/src/java/org/apache/fop/render/PrintRendererConfigurator.java b/src/java/org/apache/fop/render/PrintRendererConfigurator.java
index 806331e88..e01750b99 100644
--- a/src/java/org/apache/fop/render/PrintRendererConfigurator.java
+++ b/src/java/org/apache/fop/render/PrintRendererConfigurator.java
@@ -42,6 +42,7 @@ import org.apache.fop.apps.FOPException;
import org.apache.fop.apps.FOUserAgent;
import org.apache.fop.apps.FopFactory;
import org.apache.fop.fonts.EmbedFontInfo;
+import org.apache.fop.fonts.EncodingMode;
import org.apache.fop.fonts.FontCache;
import org.apache.fop.fonts.FontEventAdapter;
import org.apache.fop.fonts.FontEventListener;
@@ -425,8 +426,11 @@ public class PrintRendererConfigurator extends AbstractRendererConfigurator
}
boolean useKerning = fontCfg.getAttributeAsBoolean("kerning", true);
+ EncodingMode encodingMode = EncodingMode.valueOf(
+ fontCfg.getAttribute("encoding-mode", EncodingMode.AUTO.getName()));
EmbedFontInfo embedFontInfo
= new EmbedFontInfo(metricsUrl, useKerning, tripletList, embedUrl, subFont);
+ embedFontInfo.setEncodingMode(encodingMode);
if (fontCache != null) {
if (!fontCache.containsFont(embedFontInfo)) {
fontCache.addFont(embedFontInfo);
diff --git a/src/java/org/apache/fop/render/java2d/ConfiguredFontCollection.java b/src/java/org/apache/fop/render/java2d/ConfiguredFontCollection.java
index 26d64af74..9f96087b9 100644
--- a/src/java/org/apache/fop/render/java2d/ConfiguredFontCollection.java
+++ b/src/java/org/apache/fop/render/java2d/ConfiguredFontCollection.java
@@ -28,6 +28,7 @@ import org.apache.commons.logging.LogFactory;
import org.apache.fop.fonts.CustomFont;
import org.apache.fop.fonts.EmbedFontInfo;
+import org.apache.fop.fonts.EncodingMode;
import org.apache.fop.fonts.FontCollection;
import org.apache.fop.fonts.FontInfo;
import org.apache.fop.fonts.FontLoader;
@@ -87,7 +88,7 @@ public class ConfiguredFontCollection implements FontCollection {
font = new CustomFontMetricsMapper(fontMetrics, fontSource);
} else {
CustomFont fontMetrics = FontLoader.loadFont(
- fontFile, null, true, fontResolver);
+ fontFile, null, true, EncodingMode.AUTO, fontResolver);
font = new CustomFontMetricsMapper(fontMetrics);
}