xmlgraphics-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vhenneb...@apache.org
Subject svn commit: r1309884 [1/4] - in /xmlgraphics/commons/branches/Temp_TrueTypeInPostScript: ./ examples/java/java2d/ps/ src/documentation/ src/documentation/content/xdocs/ src/java/org/apache/xmlgraphics/image/codec/png/ src/java/org/apache/xmlgraphics/im...
Date Thu, 05 Apr 2012 14:36:23 GMT
Author: vhennebert
Date: Thu Apr  5 14:36:20 2012
New Revision: 1309884

URL: http://svn.apache.org/viewvc?rev=1309884&view=rev
Log:
Merged changes from trunk up to revision 1297493

Added:
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/examples/java/java2d/ps/EPSColorsExample.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/examples/java/java2d/ps/EPSColorsExample.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/sign-and-deploy.pom.xml
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/sign-and-deploy.pom.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/bugs.xml
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/documentation/content/xdocs/bugs.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/AbstractDeviceSpecificColorSpace.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/AbstractDeviceSpecificColorSpace.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/CIELabColorSpace.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/CIELabColorSpace.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ColorSpaceOrigin.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/ColorSpaceOrigin.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ColorSpaces.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/ColorSpaces.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ColorWithAlternatives.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/ColorWithAlternatives.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/GrayScaleColorConverter.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/GrayScaleColorConverter.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ICCColorSpaceWithIntent.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/ICCColorSpaceWithIntent.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/NamedColorSpace.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/NamedColorSpace.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/RenderingIntent.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/RenderingIntent.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/package.html
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/package.html
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/profile/
      - copied from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/profile/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/profile/ColorProfileUtil.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/profile/ColorProfileUtil.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfile.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfile.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfileParser.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfileParser.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/profile/package.html
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/color/profile/package.html
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/ps/PSGraphicsConfiguration.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/ps/PSGraphicsConfiguration.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/ps/PSGraphicsDevice.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/src/java/org/apache/xmlgraphics/java2d/ps/PSGraphicsDevice.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/images/dirOnly.tif
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/images/dirOnly.tif
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/image/loader/impl/
      - copied from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/image/loader/impl/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/image/loader/impl/ImageLoaderRawCCITTFaxTestCase.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/image/loader/impl/ImageLoaderRawCCITTFaxTestCase.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/image/writer/ImageWriterRegistryTest.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/image/writer/ImageWriterRegistryTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/
      - copied from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/
      - copied from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/ColorConverterTest.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/ColorConverterTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/ColorWithAlternativesTest.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/ColorWithAlternativesTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/NamedColorTest.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/NamedColorTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/profile/
      - copied from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/profile/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfileParserTest.java
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/java/org/apache/xmlgraphics/java2d/color/profile/NamedColorProfileParserTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/resources/org/apache/xmlgraphics/java2d/
      - copied from r1308326, xmlgraphics/commons/trunk/test/resources/org/apache/xmlgraphics/java2d/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/resources/org/apache/xmlgraphics/java2d/color/
      - copied from r1308326, xmlgraphics/commons/trunk/test/resources/org/apache/xmlgraphics/java2d/color/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/resources/org/apache/xmlgraphics/java2d/color/profile/
      - copied from r1308326, xmlgraphics/commons/trunk/test/resources/org/apache/xmlgraphics/java2d/color/profile/
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/resources/org/apache/xmlgraphics/java2d/color/profile/ncp-example.icc
      - copied unchanged from r1308326, xmlgraphics/commons/trunk/test/resources/org/apache/xmlgraphics/java2d/color/profile/ncp-example.icc
Removed:
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/writer/internal/JPEGImageWriter.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/schemas/pdf/PDFAOldXMPSchema.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/image/writer/internal/TIFFImageWriterTest.java
Modified:
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/   (props changed)
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/build.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/download.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/image-loader.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/index.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/postscript.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/site.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/tabs.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/skinconf.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageDecoder.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageEncoder.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGRed.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFDirectory.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFEncodeParam.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFField.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFImage.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFImageDecoder.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFImageEncoder.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/util/ForwardSeekableStream.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/util/SeekableStream.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/util/SimpleRenderedImage.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/loader/impl/ImageLoaderInternalTIFF.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/loader/impl/ImageLoaderRawCCITTFax.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/loader/impl/ImageLoaderRawJPEG.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/loader/impl/ImageRendered.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/loader/impl/imageio/ImageLoaderImageIO.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/writer/ImageWriterRegistry.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/writer/internal/TIFFImageWriter.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/StrokingTextHandler.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/TextHandler.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ColorConverter.java   (contents, props changed)
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/ColorUtil.java   (contents, props changed)
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/DefaultColorConverter.java   (contents, props changed)
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/color/DeviceCMYKColorSpace.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/ps/PSGraphics2D.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/ps/PSTextHandler.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/java2d/ps/PSTilingPattern.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/ps/DSCConstants.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/ps/PSGenerator.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/ps/PSState.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/util/Service.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/Metadata.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/XMPArray.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/XMPConstants.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/XMPSchemaAdapter.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/xmp/XMPSchemaRegistry.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/resources/META-INF/services/org.apache.xmlgraphics.image.writer.ImageWriter
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/resources/org/apache/xmlgraphics/image/writer/default-preferred-order.properties
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/status.xml
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/xmp/DateFormattingTest.java
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/test/java/org/apache/xmlgraphics/xmp/XMPPropertyTest.java   (contents, props changed)
    xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/xmlgraphics-commons-pom-template.pom

Propchange: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/
------------------------------------------------------------------------------
  Merged /xmlgraphics/commons/branches/Temp_Color:r956483-1051413
  Merged /xmlgraphics/commons/trunk:r989190-1308326

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/build.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/build.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/build.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/build.xml Thu Apr  5 14:36:20 2012
@@ -30,8 +30,8 @@
   <property name="javac.debug" value="on"/>
   <property name="javac.optimize" value="off"/>
   <property name="javac.deprecation" value="on"/>
-  <property name="javac.source" value="1.4"/>
-  <property name="javac.target" value="1.4"/>
+  <property name="javac.source" value="1.5"/>
+  <property name="javac.target" value="1.5"/>
   <property name="javac.fork" value="no"/>
 
   <property name="junit.fork" value="on"/>
@@ -123,26 +123,11 @@
   <target name="init" depends="info, init-avail"/>
 
   <target name="init-avail">
-    <available property="jdk14.present" classname="java.lang.CharSequence"/>
-    <fail message="${Name} requires at least Java 1.4" unless="jdk14.present"/>
+    <available property="jdk15.present" classname="java.lang.StringBuilder"/>
+    <fail message="${Name} requires at least Java 1.5" unless="jdk15.present"/>
     
-    <available property="sun.jpeg.present" classname="com.sun.image.codec.jpeg.JPEGCodec"/>
-    <condition property="sun.jpeg.message" value="Sun-private JPEG Support PRESENT">
-      <equals arg1="${sun.jpeg.present}" arg2="true"/>
-    </condition>
-    <condition property="sun.jpeg.message" value="Sun-private JPEG Support NOT Present">
-      <not>
-        <equals arg1="${sun.jpeg.present}" arg2="true"/>
-      </not>
-    </condition>
-    <echo message="${sun.jpeg.message}"/>
     <condition property="internal-codecs.eff.disabled">
-      <or>
-        <not>
-          <equals arg1="${sun.jpeg.present}" arg2="true"/>
-        </not>
-        <equals arg1="${internal-codecs.disabled}" arg2="true"/>
-      </or>
+      <equals arg1="${internal-codecs.disabled}" arg2="true"/>
     </condition>
 
     <available property="junit.present" classname="junit.framework.TestCase"
@@ -209,7 +194,6 @@
     <patternset id="compile-pattern">
       <include name="**/*.java"/>
       <exclude name="**/image/codec/tiff/**/*.java"/>
-      <exclude name="**/image/writer/internal/JPEGImageWriter*.java"/>
       <exclude name="**/image/writer/internal/TIFFImageWriter*.java"/>
     </patternset>
   </target>
@@ -268,7 +252,6 @@
   <target name="uptodate-jar-sources" depends="init">
     <uptodate property="jar.sources.uptodate" targetfile="${build.dir}/${name}-${version}-sources.jar">
       <srcfiles dir="${src.java.dir}"/>
-      <srcfiles dir="${src.java.version.dir}"/>
     </uptodate>
   </target>
 
@@ -337,7 +320,6 @@
         <fileset dir="${basedir}/test/java">
           <include name="**/*Test*.java"/>
           <exclude name="**/*TestSuite.java"/>
-          <exclude name="**/image/writer/internal/JPEGImageWriter*.java" if="internal-codecs.eff.disabled"/>
           <exclude name="**/image/writer/internal/TIFFImageWriter*.java" if="internal-codecs.eff.disabled"/>
         </fileset>
       </batchtest>
@@ -398,6 +380,7 @@ NOTE:
         source="${javac.source}">
       <header><![CDATA[${name} ${version}]]></header>
       <footer><![CDATA[${name} ${version}]]></footer>
+      <link offline="false" href="http://java.sun.com/j2se/1.5.0/docs/api/"/>
       <classpath>
         <path refid="libs-build-classpath"/>
         <pathelement path="${java.class.path}"/>
@@ -657,16 +640,55 @@ NOTE:
     <filter  token="version" value="${version}"/>
     <mkdir dir="${build.dir}/maven"/>
     <copy file="${basedir}/xmlgraphics-commons-pom-template.pom" tofile="${build.dir}/maven/pom.xml" filtering="true"/>
+    <fileset id="bundle-files" dir="${build.dir}">
+      <patternset>
+      <include name="${name}-${version}.jar"/>
+      <include name="${name}-${version}-sources.jar"/>
+      <include name="${name}-${version}-javadoc.jar"/>
+      </patternset>
+      <patternset>
+      <include name="maven/pom.xml"/>
+      </patternset>
+    </fileset>
+    <checksum algorithm="md5">
+      <fileset refid="bundle-files"/>
+    </checksum>
+    <checksum algorithm="sha1">
+      <fileset refid="bundle-files"/>
+    </checksum>
+    <input message="Passphrase for your default private key (attention: passphrase will be echoed in clear text on the display!)" addproperty="pwd"/>
+    <antcall target="sign-file">
+      <param name="sign.archive" value="${build.dir}/${name}-${version}.jar"/>
+      <param name="pwd" value="${pwd}"/>
+    </antcall>
+    <antcall target="sign-file">
+      <param name="sign.archive" value="${build.dir}/${name}-${version}-sources.jar"/>
+      <param name="pwd" value="${pwd}"/>
+    </antcall>
+    <antcall target="sign-file">
+      <param name="sign.archive" value="${build.dir}/${name}-${version}-javadoc.jar"/>
+      <param name="pwd" value="${pwd}"/>
+    </antcall>
+    <antcall target="sign-file">
+      <param name="sign.archive" value="${build.dir}/maven/pom.xml"/>
+      <param name="pwd" value="${pwd}"/>
+    </antcall>
     <jar jarfile="${build.dir}/${name}-${version}-bundle.jar">
       <manifest>
         <attribute name="Build-Id" value="${ts} (${user.name} [${os.name} ${os.version} ${os.arch}, Java ${java.runtime.version}])"/>
       </manifest>
       <fileset dir="${build.dir}">
-        <include name="${name}-${version}.jar"/>
-        <include name="${name}-${version}-sources.jar"/>
-        <include name="${name}-${version}-javadoc.jar"/>
+        <patternset>
+          <include name="${name}-${version}.jar*"/>
+          <include name="${name}-${version}-sources.jar*"/>
+          <include name="${name}-${version}-javadoc.jar*"/>
+        </patternset>
+      </fileset>
+      <fileset dir="${build.dir}/maven">
+        <patternset>
+          <include name="pom.xml*"/>
+        </patternset>
       </fileset>
-      <fileset dir="${build.dir}/maven"/>
       <metainf dir="${basedir}" includes="LICENSE,NOTICE"/>
     </jar>
     <move file="${build.dir}/${name}-${version}-bundle.jar" todir="${basedir}"/>

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/download.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/download.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/download.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/download.xml Thu Apr  5 14:36:20 2012
@@ -18,14 +18,14 @@
 <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
 <document> 
   <header> 
-    <title>Download Apache XML Graphics Commons</title> 
+    <title>Download Apache™ XML Graphics Commons</title> 
   </header> 
   <body> 
     <section id="release">
       <title>Download a Release</title>
       <p>
         Source ("-src") and binary ("-bin") distributions can be downloaded from a
-        <a href="http://www.apache.org/dyn/closer.cgi/xmlgraphics/commons">Apache XML Graphics Commons Distribution Mirror</a>.
+        <a href="http://www.apache.org/dyn/closer.cgi/xmlgraphics/commons">Apache™ XML Graphics Commons Distribution Mirror</a>.
       </p>
     </section>
     <section id="svn">

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/image-loader.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/image-loader.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/image-loader.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/image-loader.xml Thu Apr  5 14:36:20 2012
@@ -18,13 +18,13 @@
 <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
 <document>
   <header>
-    <title>Image Loader Framework</title>
+    <title>Apache™ XML Graphics Commons: Image Loader Framework</title>
   </header>
   <body>
     <section id="overview">
       <title>Overview</title>
       <p>
-        Apache XML Graphics Commons contains a unified framework for loading and
+        Apache™ XML Graphics Commons contains a unified framework for loading and
         processing images (bitmap and vector). The package name is
         <code>org.apache.xmlgraphics.image.loader</code>. Key features:
       </p>

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/index.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/index.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/index.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/index.xml Thu Apr  5 14:36:20 2012
@@ -18,18 +18,22 @@
 <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
 <document> 
   <header> 
-    <title>Apache XML Graphics Commons</title>
+    <title>Apache™ XML Graphics Commons</title>
   </header> 
   <body> 
     <section>
       <title>Overview</title>
       <p>
-        Apache XML Graphics Commons is a library that consists of several reusable components 
+        Apache™ XML Graphics Commons is a library that consists of several reusable components 
         used by <a href="ext:batik">Apache Batik</a> and <a href="ext:fop">Apache FOP</a>. 
         Many of these components can easily be used separately outside the domains of SVG 
         and XSL-FO. You will find components such as a PDF library, an RTF library, Graphics2D 
         implementations that let you generate PDF &amp; PostScript files, and much more.
       </p>
+      <p>The Apache™ XML Graphics Commons project is part of the <a href="http://www.apache.org">Apache™</a>
+        Software Foundation, which is a wider community of users and developers of open
+		source projects.
+      </p>
       <p>
         In the Wiki, we have a 
         <a href="http://wiki.apache.org/xmlgraphics/XmlGraphicsCommonComponents">Roadmap for Apache XML Graphics Commons</a>.

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/postscript.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/postscript.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/postscript.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/postscript.xml Thu Apr  5 14:36:20 2012
@@ -24,7 +24,7 @@
     <section id="overview">
       <title>Overview</title>
       <p>
-        Apache XML Graphics Commons contains various tools for writing and processing Adobe 
+        Apache™ XML Graphics Commons contains various tools for writing and processing Adobe 
         PostScript files. This includes:
       </p>
       <ul>

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/site.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/site.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/site.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/site.xml Thu Apr  5 14:36:20 2012
@@ -1,4 +1,4 @@
-<?xml version="1.0"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
   Licensed to the Apache Software Foundation (ASF) under one or more
   contributor license agreements.  See the NOTICE file distributed with
@@ -32,11 +32,13 @@ See http://forrest.apache.org/docs/linki
 
 <site label="XMLGraphicsCommons" href="" xmlns="http://apache.org/forrest/linkmap/1.0" tab="">
 
-  <about label="XML Graphics Commons">
+  <about label="Apache™ XML Graphics Commons">
     <index label="Overview" href="index.html" description="Overview"/>
     <download label="Download" href="download.html" description="Download"/>
+	<asf-license label="Apache License" href="http://www.apache.org/licenses"/>"
     <asf-sponsorship label="ASF Sponsorship Program" href="http://www.apache.org/foundation/sponsorship.html"/>"
     <asf-thanks label="ASF Thanks" href="http://www.apache.org/foundation/thanks.html"/>"
+	<asf-security label="Security" href="http://www.apache.org/security/"/>
     <documentation label="Documentation">
       <postscript label="Tools for Adobe PostScript" href="postscript.html" description="Tools for Adobe PostScript"/>
       <image-loader label="Image Loader Framework" href="image-loader.html" description="Image Loader Framework"/>
@@ -45,6 +47,7 @@ See http://forrest.apache.org/docs/linki
       <mail label="Mailing Lists" href="http://xmlgraphics.apache.org/mail.html" description="Information on Mailing Lists"/>
       <repo label="Code Repositories" href="http://xmlgraphics.apache.org/repo.html" description="Information on Code Repositories"/>
       <changes label="Changes" href="changes.html"/>
+	  <bugs label="Bugs" href="bugs.html"/>
     </information>
   </about>
 

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/tabs.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/tabs.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/tabs.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/content/xdocs/tabs.xml Thu Apr  5 14:36:20 2012
@@ -19,7 +19,7 @@
 
 <tabs software="XMLGraphicsCommons"
   title="XMLGraphicsCommons"
-  copyright="The Apache Software Foundation"
+  copyright="@year@ The Apache Software Foundation"
   xmlns:xlink="http://www.w3.org/1999/xlink">
 
   <!-- The rules for tabs are:

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/skinconf.xml
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/skinconf.xml?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/skinconf.xml (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/documentation/skinconf.xml Thu Apr  5 14:36:20 2012
@@ -1,4 +1,4 @@
-<?xml version="1.0"?>
+<?xml version="1.0" encoding="UTF-8"?>
 <!--
   Licensed to the Apache Software Foundation (ASF) under one or more
   contributor license agreements.  See the NOTICE file distributed with
@@ -66,7 +66,7 @@ which will be used to configure the chos
 
   <!-- mandatory project logo
        default skin: renders it at the top -->
-  <project-name>Apache XML Graphics Commons</project-name>
+  <project-name>Apache™ XML Graphics Commons</project-name>
   <project-description>Common components for Apache Batik and Apache FOP</project-description>
   <project-url>http://xmlgraphics.apache.org/commons/</project-url>
   <project-logo></project-logo>
@@ -90,12 +90,15 @@ which will be used to configure the chos
   <favicon-url>favicon.ico</favicon-url>
 
   <!-- The following are used to construct a copyright statement -->
-  <year>2006-2008</year>
+  <year>2006-2012</year>
   <vendor>The Apache Software Foundation.</vendor>
   <!-- The optional copyright-link URL will be used as a link in the
     copyright statement
   -->
   <copyright-link>http://www.apache.org/licenses/</copyright-link>
+  <trademark-statement>
+    Apache, Apache XML Graphics Commons, and the Apache feather logo are trademarks of The Apache Software Foundation. All other marks mentioned may be trademarks or registered trademarks of their respective owners.
+  </trademark-statement>
 
   <!-- Some skins use this to form a 'breadcrumb trail' of links.
     Use location="alt" to move the trail to an alternate location
@@ -105,9 +108,8 @@ which will be used to configure the chos
     For some skins just set the attributes to blank.
   -->
   <trail location="alt">
-    <link1 name="apache.org" href="http://www.apache.org/"/>
-    <link2 name="XML Federation" href="http://xml.apache.org/"/>
-    <link3 name="xmlgraphics.apache.org" href="http://xmlgraphics.apache.org/"/>
+    <link1 name="The Apache Software Foundation" href="http://www.apache.org/"/>
+    <link2 name="Apache XML Graphics Project" href="http://xmlgraphics.apache.org/"/>
   </trail>
 
   <!-- Configure the TOC, i.e. the Table of Contents.
@@ -362,25 +364,17 @@ which will be used to configure the chos
       <height>125</height>
     </credit>
     -->
-	<!--
-    <credit box-location="alt2">
-      <name>ApacheCon US 2009</name>
-      <url>http://us.apachecon.com/</url>
-      <image>http://apache.org/ads/ApacheCon/2009-usa-125x125.png</image>
-      <width>125</width>
-      <height>125</height>
-    </credit>
-	-->
     
     <!-- A credit with @role="pdf" will be used to compose a footer
      for each page in the PDF, using either "name" or "url" or both.
     -->
-    <!--
     <credit role="pdf">
-      <name>Built with Apache Forrest</name>
-      <url>http://forrest.apache.org/</url>
+      <name>PDF created by Apache FOP</name>
+      <url>http://xmlgraphics.apache.org/fop/</url>
+      <image>images/logo.jpg</image>
+      <width>138</width>
+      <height>31</height>
     </credit>
-    -->
   </credits>
 
 </skinconfig>

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageDecoder.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageDecoder.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageDecoder.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageDecoder.java Thu Apr  5 14:36:20 2012
@@ -62,6 +62,7 @@ public class PNGImageDecoder extends Ima
         super(input, param);
     }
 
+    @Override
     public RenderedImage decodeAsRenderedImage(int page) throws IOException {
         if (page != 0) {
             throw new IOException(PropertyUtil.getString("PNGImageDecoder19"));
@@ -76,19 +77,19 @@ class PNGChunk {
     byte[] data;
     int crc;
 
-    String typeString;
+    final String typeString;
 
-    public PNGChunk(int length, int type, byte[] data, int crc) {
+    PNGChunk(int length, int type, byte[] data, int crc) {
         this.length = length;
         this.type = type;
         this.data = data;
         this.crc = crc;
 
-        typeString = "";
-        typeString += (char)(type >> 24);
-        typeString += (char)((type >> 16) & 0xff);
-        typeString += (char)((type >> 8) & 0xff);
-        typeString += (char)(type & 0xff);
+        typeString = ""
+                     + (char)((type >>> 24) & 0xff)
+                     + (char)((type >>> 16) & 0xff)
+                     + (char)((type >>>  8) & 0xff)
+                     + (char)((type       ) & 0xff);
     }
 
     public int getLength() {
@@ -1220,21 +1221,21 @@ class PNGImage extends SimpleRenderedIma
     }
 
     private void parse_tEXt_chunk(PNGChunk chunk) {
-        String key = "";   // todo simplify this
-        String value = ""; // todo simplify this
-        byte b;
 
+        byte b;
+        StringBuffer key = new StringBuffer();
         int textIndex = 0;
         while ((b = chunk.getByte(textIndex++)) != 0) {
-            key += (char)b;
+            key.append( (char)b );
         }
 
+        StringBuilder value = new StringBuilder();
         for (int i = textIndex; i < chunk.getLength(); i++) {
-            value += (char)chunk.getByte(i);
+            value.append((char)chunk.getByte(i));
         }
 
-        textKeys.add(key);
-        textStrings.add(value);
+        textKeys.add(key.toString());
+        textStrings.add(value.toString());
     }
 
     private void parse_tIME_chunk(PNGChunk chunk) {
@@ -1339,16 +1340,16 @@ class PNGImage extends SimpleRenderedIma
     }
 
     private void parse_zTXt_chunk(PNGChunk chunk) {
-        String key = "";    // todo simplify this
-        String value = "";  // todo simplify this
-        byte b;
 
         int textIndex = 0;
+        StringBuffer key = new StringBuffer();
+        byte b;
         while ((b = chunk.getByte(textIndex++)) != 0) {
-            key += (char)b;
+            key.append( (char)b );
         }
         /* int method = */ chunk.getByte(textIndex++);
 
+        StringBuffer value = new StringBuffer();
         try {
             int length = chunk.getLength() - textIndex;
             byte[] data = chunk.getData();
@@ -1358,11 +1359,11 @@ class PNGImage extends SimpleRenderedIma
 
             int c;
             while ((c = iis.read()) != -1) {
-                value += (char)c;
+                value.append((char)c);
             }
 
-            ztextKeys.add(key);
-            ztextStrings.add(value);
+            ztextKeys.add(key.toString());
+            ztextStrings.add(value.toString());
         } catch (Exception e) {
             e.printStackTrace();
         }
@@ -1445,21 +1446,6 @@ class PNGImage extends SimpleRenderedIma
         }
     }
 
-    private static int paethPredictor(int a, int b, int c) {
-        int p = a + b - c;
-        int pa = Math.abs(p - a);
-        int pb = Math.abs(p - b);
-        int pc = Math.abs(p - c);
-
-        if ((pa <= pb) && (pa <= pc)) {
-            return a;
-        } else if (pb <= pc) {
-            return b;
-        } else {
-            return c;
-        }
-    }
-
     private static void decodePaethFilter(byte[] curr, byte[] prev,
                                           int count, int bpp) {
         int raw, priorPixel, priorRow, priorRowPixel;
@@ -1477,7 +1463,7 @@ class PNGImage extends SimpleRenderedIma
             priorRow = prev[i] & 0xff;
             priorRowPixel = prev[i - bpp] & 0xff;
 
-            curr[i] = (byte)(raw + paethPredictor(priorPixel,
+            curr[i] = (byte)(raw + PNGEncodeParam.paethPredictor(priorPixel,
                                                   priorRow,
                                                   priorRowPixel));
         }

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageEncoder.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageEncoder.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageEncoder.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGImageEncoder.java Thu Apr  5 14:36:20 2012
@@ -19,8 +19,6 @@
 
 package org.apache.xmlgraphics.image.codec.png;
 
-import org.apache.xmlgraphics.image.codec.util.ImageEncoderImpl;
-
 import java.awt.Rectangle;
 import java.awt.image.ColorModel;
 import java.awt.image.IndexColorModel;
@@ -40,6 +38,8 @@ import java.util.TimeZone;
 import java.util.zip.Deflater;
 import java.util.zip.DeflaterOutputStream;
 
+import org.apache.xmlgraphics.image.codec.util.ImageEncoderImpl;
+
 class CRC {
 
     private static int[] crcTable = new int[256];
@@ -78,21 +78,24 @@ class ChunkStream extends OutputStream i
     private ByteArrayOutputStream baos;
     private DataOutputStream dos;
 
-    public ChunkStream(String type) throws IOException {
+    ChunkStream(String type) throws IOException {
         this.type = type;
 
         this.baos = new ByteArrayOutputStream();
         this.dos = new DataOutputStream(baos);
     }
 
+    @Override
     public void write(byte[] b) throws IOException {
         dos.write(b);
     }
 
+    @Override
     public void write(byte[] b, int off, int len) throws IOException {
         dos.write(b, off, len);
     }
 
+    @Override
     public void write(int b) throws IOException {
         dos.write(b);
     }
@@ -163,17 +166,31 @@ class ChunkStream extends OutputStream i
         crc = CRC.updateCRC(crc, data, 0, len);
         output.writeInt(crc ^ 0xffffffff);
     }
+
+    /** {@inheritDoc} */
+    @Override
+    public void close() throws IOException {
+
+        if ( baos != null ) {
+            baos.close();
+            baos = null;
+        }
+        if (dos != null) {
+            dos.close();
+            dos = null;
+        }
+    }
 }
 
 
 class IDATOutputStream extends FilterOutputStream {
 
-    private static final byte[] typeSignature =
-      {(byte)'I', (byte)'D', (byte)'A', (byte)'T'};
+    private static final byte[] typeSignature
+         = {(byte)'I', (byte)'D', (byte)'A', (byte)'T'};
 
     private int bytesWritten = 0;
     private int segmentLength;
-    byte[] buffer;
+    private byte[] buffer;
 
     public IDATOutputStream(OutputStream output,
                             int segmentLength) {
@@ -182,6 +199,7 @@ class IDATOutputStream extends FilterOut
         this.buffer = new byte[segmentLength];
     }
 
+    @Override
     public void close() throws IOException {
         flush();
     }
@@ -193,7 +211,12 @@ class IDATOutputStream extends FilterOut
         out.write(x & 0xff);
     }
 
+    @Override
     public void flush() throws IOException {
+        if (bytesWritten == 0) {
+            return;
+        }
+
         // Length
         writeInt(bytesWritten);
         // 'IDAT' signature
@@ -212,10 +235,12 @@ class IDATOutputStream extends FilterOut
         bytesWritten = 0;
     }
 
+    @Override
     public void write(byte[] b) throws IOException {
         this.write(b, 0, b.length);
     }
 
+    @Override
     public void write(byte[] b, int off, int len) throws IOException {
         while (len > 0) {
             int bytes = Math.min(segmentLength - bytesWritten, len);
@@ -230,6 +255,7 @@ class IDATOutputStream extends FilterOut
         }
     }
 
+    @Override
     public void write(int b) throws IOException {
         buffer[bytesWritten++] = (byte)b;
         if (bytesWritten == segmentLength) {
@@ -305,6 +331,7 @@ public class PNGImageEncoder extends Ima
         cs.writeByte(interlace ? (byte)1 : (byte)0);
 
         cs.writeToStream(dataOutput);
+        cs.close();
     }
 
     private byte[] prevRow = null;
@@ -483,12 +510,15 @@ public class PNGImageEncoder extends Ima
         }
 
         dos.finish();
+        dos.close();
         ios.flush();
+        ios.close();
     }
 
     private void writeIEND() throws IOException {
         ChunkStream cs = new ChunkStream("IEND");
         cs.writeToStream(dataOutput);
+        cs.close();
     }
 
     private static final float[] srgbChroma = {
@@ -510,6 +540,7 @@ public class PNGImageEncoder extends Ima
                 cs.writeInt((int)(chroma[i]*100000));
             }
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -527,6 +558,7 @@ public class PNGImageEncoder extends Ima
             // everything is different.
             cs.writeInt((int)(gamma*100000/*+0.5*/));
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -536,6 +568,7 @@ public class PNGImageEncoder extends Ima
             byte[] ICCProfileData = param.getICCProfileData();
             cs.write(ICCProfileData);
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -548,6 +581,7 @@ public class PNGImageEncoder extends Ima
                 cs.writeByte(significantBits[i]);
             }
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -558,6 +592,7 @@ public class PNGImageEncoder extends Ima
             int intent = param.getSRGBIntent();
             cs.write(intent);
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -574,6 +609,7 @@ public class PNGImageEncoder extends Ima
         }
 
         cs.writeToStream(dataOutput);
+        cs.close();
     }
 
     private void writeBKGD() throws IOException {
@@ -603,6 +639,7 @@ public class PNGImageEncoder extends Ima
             }
 
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -616,6 +653,7 @@ public class PNGImageEncoder extends Ima
             }
 
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -642,6 +680,7 @@ public class PNGImageEncoder extends Ima
             }
 
             cs.writeToStream(dataOutput);
+            cs.close();
         } else if (colorType == PNG_COLOR_PALETTE) {
             int lastEntry = Math.min(255, alphaPalette.length - 1);
             int nonOpaque;
@@ -657,6 +696,7 @@ public class PNGImageEncoder extends Ima
                     cs.writeByte(alphaPalette[i]);
                 }
                 cs.writeToStream(dataOutput);
+                cs.close();
             }
         }
     }
@@ -671,6 +711,7 @@ public class PNGImageEncoder extends Ima
             cs.writeByte((byte)dims[2]);
 
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -681,6 +722,7 @@ public class PNGImageEncoder extends Ima
             System.out.println("sPLT not supported yet.");
 
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -709,6 +751,7 @@ public class PNGImageEncoder extends Ima
             cs.writeByte(second);
 
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -727,6 +770,7 @@ public class PNGImageEncoder extends Ima
                 cs.write(value);
 
                 cs.writeToStream(dataOutput);
+                cs.close();
             }
         }
     }
@@ -748,8 +792,10 @@ public class PNGImageEncoder extends Ima
                 DeflaterOutputStream dos = new DeflaterOutputStream(cs);
                 dos.write(value);
                 dos.finish();
+                dos.close();
 
                 cs.writeToStream(dataOutput);
+                cs.close();
             }
         }
     }
@@ -763,6 +809,7 @@ public class PNGImageEncoder extends Ima
             ChunkStream cs = new ChunkStream(type);
             cs.write(data);
             cs.writeToStream(dataOutput);
+            cs.close();
         }
     }
 
@@ -814,6 +861,7 @@ public class PNGImageEncoder extends Ima
      * the end of the operation, this should be done if needed
      * by the caller of this method.
      */
+    @Override
     public void encode(RenderedImage im) throws IOException {
         this.image = im;
         this.width = image.getWidth();
@@ -998,5 +1046,6 @@ public class PNGImageEncoder extends Ima
         writeIEND();
 
         dataOutput.flush();
+        dataOutput.close();
     }
 }

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGRed.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGRed.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGRed.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/png/PNGRed.java Thu Apr  5 14:36:20 2012
@@ -19,8 +19,6 @@
 
 package org.apache.xmlgraphics.image.codec.png;
 
-import org.apache.xmlgraphics.image.codec.util.PropertyUtil;
-
 import java.awt.Color;
 import java.awt.Point;
 import java.awt.Rectangle;
@@ -41,17 +39,19 @@ import java.io.DataInputStream;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.SequenceInputStream;
+import java.util.ArrayList;
+import java.util.Collections;
 import java.util.Date;
 import java.util.GregorianCalendar;
-import java.util.Hashtable;
-import java.util.TimeZone;
-import java.util.Vector;
+import java.util.HashMap;
 import java.util.List;
-import java.util.ArrayList;
+import java.util.Map;
+import java.util.TimeZone;
 import java.util.zip.Inflater;
 import java.util.zip.InflaterInputStream;
 
 import org.apache.xmlgraphics.image.GraphicsUtil;
+import org.apache.xmlgraphics.image.codec.util.PropertyUtil;
 import org.apache.xmlgraphics.image.rendered.AbstractRed;
 import org.apache.xmlgraphics.image.rendered.CachableRed;
 
@@ -59,7 +59,6 @@ import org.apache.xmlgraphics.image.rend
  *
  * @version $Id$
  */
-
 public class PNGRed extends AbstractRed {
 
     static class PNGChunk {
@@ -279,7 +278,7 @@ public class PNGRed extends AbstractRed 
     private static final int POST_ADD_GRAY_TRANS_EXP =
         POST_ADD_GRAY_TRANS | POST_EXP_MASK;
 
-    private Vector streamVec = new Vector();
+    private List<InputStream> streamVec = new ArrayList<InputStream>();
     private DataInputStream dataStream;
 
     private int bytesPerPixel; // number of bytes per input pixel
@@ -297,8 +296,9 @@ public class PNGRed extends AbstractRed 
 
     private WritableRaster theTile;
     private Rectangle bounds;
+
     /** A Hashtable containing the image properties. */
-    private Hashtable properties = new Hashtable();
+    private Map<String, Object> properties = new HashMap<String, Object>();
 
 
     private int[] gammaLut = null;
@@ -479,6 +479,8 @@ public class PNGRed extends AbstractRed 
                 properties.put("significant_bits", significantBits);
             }
         }
+        distream.close();
+        stream.close();
     }
 
     private static String getChunkType(DataInputStream distream) {
@@ -748,7 +750,7 @@ public class PNGRed extends AbstractRed 
 
         // Parse prior IDAT chunks
         InputStream seqStream =
-            new SequenceInputStream(streamVec.elements());
+            new SequenceInputStream( Collections.enumeration( streamVec ));
         InputStream infStream =
             new InflaterInputStream(seqStream, new Inflater());
         dataStream = new DataInputStream(infStream);
@@ -783,6 +785,13 @@ public class PNGRed extends AbstractRed 
         }
 
         decodeImage(interlaceMethod == 1);
+
+        // Free resources associated with compressed data.
+        dataStream.close();
+        infStream.close();
+        seqStream.close();
+        streamVec = null;
+
         SampleModel sm = theTile.getSampleModel();
         ColorModel  cm;
 
@@ -1850,6 +1859,7 @@ public class PNGRed extends AbstractRed 
     }
 
     // RenderedImage stuff
+    @Override
     public Raster getTile(int tileX, int tileY) {
         if (tileX != 0 || tileY != 0) {
             // Error -- bad tile requested

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFDirectory.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFDirectory.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFDirectory.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFDirectory.java Thu Apr  5 14:36:20 2012
@@ -51,7 +51,7 @@ import org.apache.xmlgraphics.image.code
  * @see TIFFField
  * @version $Id$
  */
-public class TIFFDirectory extends Object implements Serializable {
+public class TIFFDirectory implements Serializable {
 
     /** A boolean storing the endianness of the stream. */
     boolean isBigEndian;

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFEncodeParam.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFEncodeParam.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFEncodeParam.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFEncodeParam.java Thu Apr  5 14:36:20 2012
@@ -24,8 +24,6 @@ import java.util.zip.Deflater;
 
 import org.apache.xmlgraphics.image.codec.util.ImageEncodeParam;
 
-import com.sun.image.codec.jpeg.JPEGEncodeParam;
-
 /**
  * An instance of <code>ImageEncodeParam</code> for encoding images in
  * the TIFF format.
@@ -107,7 +105,6 @@ public class TIFFEncodeParam implements 
     private TIFFField[] extraFields;
 
     private boolean convertJPEGRGBToYCbCr = true;
-    private JPEGEncodeParam jpegEncodeParam = null;
 
     private int deflateLevel = Deflater.DEFAULT_COMPRESSION;
 
@@ -115,7 +112,9 @@ public class TIFFEncodeParam implements 
      * Constructs a TIFFEncodeParam object with default values for
      * all parameters.
      */
-    public TIFFEncodeParam() {}
+    public TIFFEncodeParam() {
+        //nop
+    }
 
     /**
      * Returns the value of the compression parameter.
@@ -146,7 +145,6 @@ public class TIFFEncodeParam implements 
         switch(compression) {
         case COMPRESSION_NONE:
         case COMPRESSION_PACKBITS:
-        case COMPRESSION_JPEG_TTN2:
         case COMPRESSION_DEFLATE:
             // Do nothing.
             break;
@@ -189,9 +187,6 @@ public class TIFFEncodeParam implements 
      * of each strip is always the width of the image and the default
      * number of rows per strip is 8.
      *
-     * <p> If JPEG compession is being used, the dimensions of the strips or
-     * tiles may be modified to conform to the JPEG-in-TIFF specification.
-     *
      * @param tileWidth The tile width; ignored if strips are used.
      * @param tileHeight The tile height or number of rows per strip.
      */
@@ -252,8 +247,9 @@ public class TIFFEncodeParam implements 
      * setting is ignored if the compression type is not DEFLATE.
      */
     public void setDeflateLevel(int deflateLevel) {
-        if(deflateLevel < 1 && deflateLevel > 9 &&
-           deflateLevel != Deflater.DEFAULT_COMPRESSION) {
+        if (deflateLevel < 1
+                && deflateLevel > 9
+                && deflateLevel != Deflater.DEFAULT_COMPRESSION) {
             throw new Error("TIFFEncodeParam1");
         }
 
@@ -284,42 +280,6 @@ public class TIFFEncodeParam implements 
     }
 
     /**
-     * Sets the JPEG compression parameters.  These parameters are ignored
-     * if the compression type is not JPEG.  The argument may be
-     * <code>null</code> to indicate that default compression parameters
-     * are to be used.  For maximum conformance with the specification it
-     * is recommended in most cases that only the quality compression
-     * parameter be set.
-     *
-     * <p> The <code>writeTablesOnly</code> and <code>JFIFHeader</code>
-     * flags of the <code>JPEGEncodeParam</code> are ignored.  The
-     * <code>writeImageOnly</code> flag is used to determine whether the
-     * JPEGTables field will be written to the TIFF stream: if
-     * <code>writeImageOnly</code> is <code>true</code>, then the JPEGTables
-     * field will be written and will contain a valid JPEG abbreviated
-     * table specification datastream.  In this case the data in each data
-     * segment (strip or tile) will contain an abbreviated JPEG image
-     * datastream.  If the <code>writeImageOnly</code> flag is
-     * <code>false</code>, then the JPEGTables field will not be written and
-     * each data segment will contain a complete JPEG interchange datastream.
-     */
-    public void setJPEGEncodeParam(JPEGEncodeParam jpegEncodeParam) {
-        if(jpegEncodeParam != null) {
-            jpegEncodeParam = (JPEGEncodeParam)jpegEncodeParam.clone();
-            jpegEncodeParam.setTableInfoValid(false);
-            jpegEncodeParam.setImageInfoValid(true);
-        }
-        this.jpegEncodeParam = jpegEncodeParam;
-    }
-
-    /**
-     * Retrieves the JPEG compression parameters.
-     */
-    public JPEGEncodeParam getJPEGEncodeParam() {
-        return jpegEncodeParam;
-    }
-
-    /**
      * Sets an array of extra fields to be written to the TIFF Image File
      * Directory (IFD).  Fields with tags equal to the tag of any
      * automatically generated fields are ignored.  No error checking is

Modified: xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFField.java
URL: http://svn.apache.org/viewvc/xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFField.java?rev=1309884&r1=1309883&r2=1309884&view=diff
==============================================================================
--- xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFField.java (original)
+++ xmlgraphics/commons/branches/Temp_TrueTypeInPostScript/src/java/org/apache/xmlgraphics/image/codec/tiff/TIFFField.java Thu Apr  5 14:36:20 2012
@@ -37,7 +37,7 @@ import java.io.Serializable;
  *
  * @see TIFFDirectory
  */
-public class TIFFField extends Object implements Comparable, Serializable {
+public class TIFFField implements Comparable, Serializable {
 
     /** Flag for 8 bit unsigned integers. */
     public static final int TIFF_BYTE      =  1;



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: commits-help@xmlgraphics.apache.org


Mime
View raw message