From 1c11bf98135675a9d6b6acac4fd7856a5dde8751 Mon Sep 17 00:00:00 2001 From: Jeremias Maerki Date: Thu, 10 Feb 2011 15:22:00 +0000 Subject: [PATCH] Fix deprecation. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_Color@1069423 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/fop/pdf/PDFColorHandler.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/java/org/apache/fop/pdf/PDFColorHandler.java b/src/java/org/apache/fop/pdf/PDFColorHandler.java index fb5a0ba12..76a6cab78 100644 --- a/src/java/org/apache/fop/pdf/PDFColorHandler.java +++ b/src/java/org/apache/fop/pdf/PDFColorHandler.java @@ -30,12 +30,12 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.apache.xmlgraphics.java2d.color.CIELabColorSpace; -import org.apache.xmlgraphics.java2d.color.ColorWithAlternatives; import org.apache.xmlgraphics.java2d.color.ColorUtil; +import org.apache.xmlgraphics.java2d.color.ColorWithAlternatives; import org.apache.xmlgraphics.java2d.color.DeviceCMYKColorSpace; import org.apache.xmlgraphics.java2d.color.NamedColorSpace; +import org.apache.xmlgraphics.java2d.color.profile.ColorProfileUtil; -import org.apache.fop.util.ColorProfileUtil; import org.apache.fop.util.DecimalFormatCache; /** @@ -48,7 +48,7 @@ public class PDFColorHandler { private PDFResources resources; - private Map cieLabColorSpaces; + private Map cieLabColorSpaces; public PDFColorHandler(PDFResources resources) { this.resources = resources; @@ -149,10 +149,10 @@ public class PDFColorHandler { private PDFCIELabColorSpace getCIELabColorSpace(CIELabColorSpace labCS) { if (this.cieLabColorSpaces == null) { - this.cieLabColorSpaces = new java.util.HashMap(); + this.cieLabColorSpaces = new java.util.HashMap(); } float[] wp = labCS.getWhitePoint(); - StringBuffer sb = new StringBuffer(); + StringBuilder sb = new StringBuilder(); for (int i = 0; i < 3; i++) { if (i > 0) { sb.append(','); @@ -160,7 +160,7 @@ public class PDFColorHandler { sb.append(wp[i]); } String key = sb.toString(); - PDFCIELabColorSpace cielab = (PDFCIELabColorSpace)this.cieLabColorSpaces.get(key); + PDFCIELabColorSpace cielab = this.cieLabColorSpaces.get(key); if (cielab == null) { //color space is not in the PDF, yet float[] wp1 = new float[] {wp[0] / 100f, wp[1] / 100f, wp[2] / 100f}; -- 2.39.5