You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Lincoln <li...@oracle.com> on 2006/03/30 05:08:18 UTC

imagedirectory png width and height not generated?

The generator type "imagedirectory" doesn't appear to generate the
attributes "width" and "height" for png's. Gifs and jpg are fine.

Is there a workaround?
Am I doing something wrong?

Linc



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: imagedirectory png width and height not generated?

Posted by Jorg Heymans <jh...@domek.be>.
Lincoln wrote:
> The generator type "imagedirectory" doesn't appear to generate the
> attributes "width" and "height" for png's. Gifs and jpg are fine.
> 
> Is there a workaround?
> Am I doing something wrong?
> 

If you look at src/java/org/apache/cocoon/util/ImageUtils.java, you'll
see that it only supports gifs and jpgs for the moment.

It shouldn't be too hard to add support for other filetypes though, it
only requires to have their magic numbers and write some code to peek
into the first bytes of the file.

Jorg


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org