Re: outputting TIFF-G images
Ok, yesterday I solved this problem by intalling jai tools. My error was that I installed jai lib, but this doesn't supply any new service provider, actually I don't know if this libs are really necessary. Today I'll find a way to pass the page iterator to the tiff codec. Salut! En/na Oliver Hernàndez Valls ha escrit: I keep trying to make the TIFFRenderer work with CCITT T.6 bilevel compression (CCITT Group 4 facsimile compression). But can't make it work. When the outputStream flushes I have this exception: Caused by: java.util.NoSuchElementException at javax.imageio.spi.FilterIterator.next(ServiceRegistry.java:808) at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:820) at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:805) at org.apache.xmlgraphics.image.writer.imageio.ImageIOImageWriter.writeImage(ImageIOImageWriter.java:73) at org.apache.fop.render.bitmap.TIFFRenderer.stopRenderer(TIFFRenderer.java:196) at org.apache.fop.area.RenderPagesModel.endDocument(RenderPagesModel.java:240) at org.apache.fop.area.AreaTreeHandler.endDocument(AreaTreeHandler.java:422) at org.apache.fop.fo.FOTreeBuilder.endDocument(FOTreeBuilder.java:170) at org.apache.xml.serializer.ToXMLSAXHandler.endDocument(ToXMLSAXHandler.java:182) at org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1287) ... 43 more I think the problem I have is that the IIORegistry has no service providers for image/tiff mime types. And I don't know how to register one. Neither I know where to find one. Does somebody know how to make IIORegistry provide an encoder for tiff images?? thanks a lot in advance! this is the TIFFRenderer.java I have at present: /* * Copyright 1999-2006 The Apache Software Foundation. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ /* $Id: TIFFRenderer.java 391332 2006-04-04 15:15:23Z jeremias $ */ package org.apache.fop.render.bitmap; // Code originaly contributed by Oleg Tkachenko of Multiconn International Ltd // ([EMAIL PROTECTED]). import java.awt.image.BufferedImage; import java.awt.image.DataBuffer; import java.awt.image.PixelInterleavedSampleModel; import java.awt.image.RenderedImage; import java.awt.image.SampleModel; import java.awt.image.SinglePixelPackedSampleModel; import java.io.IOException; import java.io.OutputStream; import java.util.Iterator; import org.apache.avalon.framework.configuration.Configuration; import org.apache.avalon.framework.configuration.ConfigurationException; import org.apache.commons.logging.Log; import org.apache.fop.apps.FOPException; import org.apache.fop.apps.MimeConstants; import org.apache.fop.render.java2d.Java2DRenderer; import org.apache.xmlgraphics.image.GraphicsUtil; import org.apache.xmlgraphics.image.codec.tiff.TIFFEncodeParam; import org.apache.xmlgraphics.image.rendered.FormatRed; import org.apache.xmlgraphics.image.writer.ImageWriter; import org.apache.xmlgraphics.image.writer.ImageWriterParams; import org.apache.xmlgraphics.image.writer.imageio.ImageIOTIFFImageWriter; /** * * This class represents renderer to TIFF (Tagged Image File Format) format. It * is one of the most popular and flexible of the current public domain raster * file formats, which was is primarily designed for raster data interchange. * Supported compression types are: * * Raw noncompressed data * Byte-oriented run-length encoding "PackBits" compression. * Modified Huffman Compression (CCITT Group 3 1D facsimile compression) * CCITT T.4 bilevel compression (CCITT Group 3 2D facsimile compression) * CCITT T.6 bilevel compression (CCITT Group 4 facsimile compression) * JPEG-in-TIFF compression * DEFLATE lossless compression (also known as "Zip-in-TIFF") * LZW compression * TODO * * This class actually does not render itself, instead it extends * org.apache.fop.render.java2D.Java2DRenderer and just encode * rendering results into TIFF format using Batik's image codec */ public class TIFFRenderer extends Java2DRenderer { /** The MIME type for tiff-Rendering */ public static final String MIME_TYPE = MimeConstants.MIME_TIFF; /** */ //private TIFFEncodeParam renderParams; private ImageWriterParams iwParams= null; private OutputStream outputStream; /** @see org.apache.fop.render.AbstractRenderer */ public String getMimeType() { return MIME_TYPE; } /** Creates TIFF renderer. */ pu
RE: € Sign
Hi, That is correct you can specify the unicode number but you still need to make sure that the font you use has your required unicode glyphs. I used the "Arial Unicode MS" font found at C:\WINDOWS\Fonts on my PC which has loads of glyphs See:- http://www.alanwood.net/unicode/fonts.html#arialunicodems for details of the Unicode tables it covers. -Original Message- From: Pascal Sancho [mailto:[EMAIL PROTECTED] Sent: Thursday, 14 September 2006 9:55 PM To: fop-users@xmlgraphics.apache.org Subject: RE: € Sign > -Original Message- > From: Andreas Reuleaux [mailto:[EMAIL PROTECTED] > Sent: Thursday, September 14, 2006 1:31 PM > To: fop-users@xmlgraphics.apache.org > Subject: Re: € Sign > > On Thu, Sep 14, 2006 at 01:22:10PM +0200, Christian Loock wrote: > > Hello, > > > > i have the problem that the € sign is not displayed in my PDF. I > > Generate the PDF using FOP 0.20.5. THe Font is Arial and > the encoding > > iso-8859-1 > > > > > € is not in iso-8859-1, how about you try to you use utf-8 or > iso-8859-15? > > -Andreas Hi, You can use character entity, witch is not encoding dependant: Euro symbol can be represented by either €, or ₮ That can be done with any Unicode character. Pascal NOTICE This e-mail and any attachments are confidential and may contain copyright material of Macquarie Bank or third parties. If you are not the intended recipient of this email you should not read, print, re-transmit, store or act in reliance on this e-mail or any attachments, and should destroy all copies of them. Macquarie Bank does not guarantee the integrity of any emails or any attached files. The views or opinions expressed are the author's own and may not reflect the views or opinions of Macquarie Bank.
Re: Extra fo:inline introduces extra new lines
Pascal Sancho wrote: Hi > Tested on both FOP 0.92 (works badly) and FOP_TRUNK (works > fine), this has been corrected in latest code Ok, thanks for the info. I'll wait for 0.93 to add this functionality. And thanks to Stefan and Manuel: you're right, my samples were not well-formed (my fault, while simplifying the code to post). BTW, thanks to all FOP developers and fop-users contributors for your time. Regards, --drkm ___ Découvrez un nouveau moyen de poser toutes vos questions quelque soit le sujet ! Yahoo! Questions/Réponses pour partager vos connaissances, vos opinions et vos expériences. http://fr.answers.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [docbook-apps] Re: JAXP and docbook-xsl Stylesheets
Don Adams wrote: A HUGE thank you! Yes, after spending hours trying to figure this out, all I needed to do was change this: transformer.setOutputProperty(OutputKeys.ENCODING,"UTF-8"); to this: transformer.setOutputProperty(OutputKeys.ENCODING,"ISO-8859-1"); I think that the best is to omit this command completely. Then transformer will use encoding specified in stylesheet by encoding="..."/> and you can be sure that there will not be encoding mismatch. -- -- Jirka Kosek e-mail: [EMAIL PROTECTED] http://www.kosek.cz -- Profesionální školení a poradenství v oblasti technologií XML. Podívejte se na náš nově spuštěný web http://DocBook.cz Podrobný přehled školení http://xmlguru.cz/skoleni/ -- Nejbližší termíny školení: ** XSLT 23.-26.10.2006 ** XML schémata 13.-15.11.2006 ** ** DocBook 11.-13.12.2006 ** XSL-FO 11.-12.12.2006 ** -- http://xmlguru.czBlog mostly about XML for English readers -- smime.p7s Description: S/MIME Cryptographic Signature
Re: outputting TIFF-G images
I keep trying to make the TIFFRenderer work with CCITT T.6 bilevel compression (CCITT Group 4 facsimile compression). But can't make it work. When the outputStream flushes I have this exception: Caused by: java.util.NoSuchElementException at javax.imageio.spi.FilterIterator.next(ServiceRegistry.java:808) at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:820) at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:805) at org.apache.xmlgraphics.image.writer.imageio.ImageIOImageWriter.writeImage(ImageIOImageWriter.java:73) at org.apache.fop.render.bitmap.TIFFRenderer.stopRenderer(TIFFRenderer.java:196) at org.apache.fop.area.RenderPagesModel.endDocument(RenderPagesModel.java:240) at org.apache.fop.area.AreaTreeHandler.endDocument(AreaTreeHandler.java:422) at org.apache.fop.fo.FOTreeBuilder.endDocument(FOTreeBuilder.java:170) at org.apache.xml.serializer.ToXMLSAXHandler.endDocument(ToXMLSAXHandler.java:182) at org.apache.xalan.transformer.TransformerImpl.transformNode(TransformerImpl.java:1287) ... 43 more I think the problem I have is that the IIORegistry has no service providers for image/tiff mime types. And I don't know how to register one. Neither I know where to find one. Does somebody know how to make IIORegistry provide an encoder for tiff images?? thanks a lot in advance! this is the TIFFRenderer.java I have at present: /* * Copyright 1999-2006 The Apache Software Foundation. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ /* $Id: TIFFRenderer.java 391332 2006-04-04 15:15:23Z jeremias $ */ package org.apache.fop.render.bitmap; // Code originaly contributed by Oleg Tkachenko of Multiconn International Ltd // ([EMAIL PROTECTED]). import java.awt.image.BufferedImage; import java.awt.image.DataBuffer; import java.awt.image.PixelInterleavedSampleModel; import java.awt.image.RenderedImage; import java.awt.image.SampleModel; import java.awt.image.SinglePixelPackedSampleModel; import java.io.IOException; import java.io.OutputStream; import java.util.Iterator; import org.apache.avalon.framework.configuration.Configuration; import org.apache.avalon.framework.configuration.ConfigurationException; import org.apache.commons.logging.Log; import org.apache.fop.apps.FOPException; import org.apache.fop.apps.MimeConstants; import org.apache.fop.render.java2d.Java2DRenderer; import org.apache.xmlgraphics.image.GraphicsUtil; import org.apache.xmlgraphics.image.codec.tiff.TIFFEncodeParam; import org.apache.xmlgraphics.image.rendered.FormatRed; import org.apache.xmlgraphics.image.writer.ImageWriter; import org.apache.xmlgraphics.image.writer.ImageWriterParams; import org.apache.xmlgraphics.image.writer.imageio.ImageIOTIFFImageWriter; /** * * This class represents renderer to TIFF (Tagged Image File Format) format. It * is one of the most popular and flexible of the current public domain raster * file formats, which was is primarily designed for raster data interchange. * Supported compression types are: * * Raw noncompressed data * Byte-oriented run-length encoding "PackBits" compression. * Modified Huffman Compression (CCITT Group 3 1D facsimile compression) * CCITT T.4 bilevel compression (CCITT Group 3 2D facsimile compression) * CCITT T.6 bilevel compression (CCITT Group 4 facsimile compression) * JPEG-in-TIFF compression * DEFLATE lossless compression (also known as "Zip-in-TIFF") * LZW compression * TODO * * This class actually does not render itself, instead it extends * org.apache.fop.render.java2D.Java2DRenderer and just encode * rendering results into TIFF format using Batik's image codec */ public class TIFFRenderer extends Java2DRenderer { /** The MIME type for tiff-Rendering */ public static final String MIME_TYPE = MimeConstants.MIME_TIFF; /** */ //private TIFFEncodeParam renderParams; private ImageWriterParams iwParams= null; private OutputStream outputStream; /** @see org.apache.fop.render.AbstractRenderer */ public String getMimeType() { return MIME_TYPE; } /** Creates TIFF renderer. */ public TIFFRenderer() { //renderParams = new TIFFEncodeParam(); //Default to packbits compression which is widely supported //renderParams.setCompression(TIFFEncodeParam.COMPRESSION_PACKBITS); iwParams= new ImageWriterParams(); } private int bufferedImageType= 0; /** * Configure the TIFF r
RE: Keeping tables together with FOP 0.92b
I know that if a table has 20 or more rows, it won't fit on a single page. I deal with such large tables in my XSLT like this: page auto ... ... Here I am dealing with a situation where the number of rows on a particular table may not be very large, but because other tables appear on the page before it, the page breaks in the middle of the table, like this.: Page Break Table 1 row row row row Table 2 row row row row row row row row Table 3 row row row row Page Break row row row row Table 4 row row row row In my case, the row heights are always the same, so Louis' warning is not applicable. In order to know if I should start a new page before beginning to print Table 3, I would have to know the number of rows that already appear on the page (or some other more clever work-around), but I can't think of a way to get that information. Does this suggest a solution to anyone? Thanks. -- Charles Knell [EMAIL PROTECTED] - email ÿþ <