4 Replies Latest reply on Jul 19, 2007 4:06 PM by trickyvail

    Problem with the images in the [i]D:\jboss-seam-1.2.1. GA\se

    jsfman

      When I put my images in the directory img of D:\jboss-seam-1.2.1. GA\seam-gen\view\img, and that then I deploie my application, my images are transformed. Why and How is that the images are not to modify.
      Please, help me.

        • 1. Re: Problem with the images in the [i]D:\jboss-seam-1.2.1. G
          gavin.king

          I think someone reported that there is a bug in the Ant script that does some text replacement on image files. Check the Ant build.

          • 2. Re: Problem with the images in the [i]D:\jboss-seam-1.2.1. G

            Are you using filtering="true" anywhere in the ant build script when copying the img folder? That would corrupt the images.

            • 3. Re: Problem with the images in the [i]D:\jboss-seam-1.2.1. G
              jsfman

              No, where is exactly this parameter to put it : false

              • 4. Re: Problem with the images in the [i]D:\jboss-seam-1.2.1. G
                trickyvail

                I have also experienced corrupt image files when creating new seam-gen projects in a Linux environment. I'm not sure that this problem occurs within windows.

                There are only 3 files that are effected by this problem:

                /view/img/cal-next.png
                /view/img/cal-prev.png
                /view/img/dtpick.gif

                So it has not been a big deal to copy the files over manually.

                I've done a little research into the problem and I think it is related to the use of a filterset in the ant copy command on line 602-605 of the seam-gen build file $SEAM_HOME/seam-gen/build.xml

                <copy todir="${project.home}/view">
                 <fileset refid="view"/>
                 <filterset refid="project"/>
                 </copy>
                

                The ANT documentation (http://ant.apache.org/manual/CoreTasks/copy.html) says:
                Note: If you employ filters in your copy operation, you should limit the copy to text files. Binary files will be corrupted by the copy operation. This applies whether the filters are implicitly defined by the filter task or explicitly provided to the copy operation as filtersets. See encoding note.


                Would it be appropriate to post a JIRA issue? I think it can be resolved by copying the image files within their own copy task (without filters or filtersets).