From: Jeremias Maerki Date: Mon, 15 Sep 2008 15:06:28 +0000 (+0000) Subject: PDF Output: Made sure the XMP Metadata stream is never compressed. X-Git-Tag: fop-1_0~417 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=50b0a1cbf65b5dce664d08f751cf452772176587;p=xmlgraphics-fop.git PDF Output: Made sure the XMP Metadata stream is never compressed. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@695491 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/java/org/apache/fop/pdf/PDFFilterList.java b/src/java/org/apache/fop/pdf/PDFFilterList.java index 5eab5c81a..3025b8788 100644 --- a/src/java/org/apache/fop/pdf/PDFFilterList.java +++ b/src/java/org/apache/fop/pdf/PDFFilterList.java @@ -163,6 +163,11 @@ public class PDFFilterList { * @param type which filter list to modify */ public void addDefaultFilters(Map filters, String type) { + if (METADATA_FILTER.equals(type)) { + //XMP metadata should not be embedded in clear-text + addFilter(new NullFilter()); + return; + } List filterset = null; if (filters != null) { filterset = (List)filters.get(type); @@ -171,10 +176,7 @@ public class PDFFilterList { } } if (filterset == null || filterset.size() == 0) { - if (METADATA_FILTER.equals(type)) { - //XMP metadata should not be embedded in clear-text - addFilter(new NullFilter()); - } else if (JPEG_FILTER.equals(type)) { + if (JPEG_FILTER.equals(type)) { //JPEG is already well compressed addFilter(new NullFilter()); } else if (TIFF_FILTER.equals(type)) { diff --git a/status.xml b/status.xml index 8fc7c7b07..637445cfa 100644 --- a/status.xml +++ b/status.xml @@ -53,6 +53,9 @@ + + PDF Output: Made sure the XMP Metadata stream is never compressed. + Fix for PFMReader after bug #43089 changed the behavior of PFMFile. Fixes baseline problems when Type 1 fonts are used in conjunction with XML font metric files.