Re: fop error
we have solved the problem by setting the systemproperty java.awt.headless System.setProperty (java.awt.headless, true); thmarx wrote: Hello everybody. We use fop.0.20.5 to produce pdf files at our linux server. It works most times. But after some times we got the following error message: [WARNING] table-layout=auto is not supported, using fixed! Xlib: connection to localhost:0.0 refused by server Xlib: No protocol specified java.lang.InternalError: Can't connect to X11 window server using 'localhost:0' as the value of the DISPLAY variable. at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method) at sun.awt.X11GraphicsEnvironment.clinit(X11GraphicsEnvironment.java:126) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:130) at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62) at sun.awt.motif.MToolkit.clinit(MToolkit.java:70) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:130) at java.awt.Toolkit$2.run(Toolkit.java:712) at java.security.AccessController.doPrivileged(Native Method) at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:703) at java.awt.SystemColor.updateSystemColors(SystemColor.java:417) at java.awt.SystemColor.clinit(SystemColor.java:409) at org.apache.batik.css.value.DefaultSystemColorResolver.activeBorder(DefaultSystemColorResolver.java:27) at org.apache.batik.css.value.ColorFactory.init(ColorFactory.java:75) at org.apache.batik.css.value.CommonValueFactoryMap.init(CommonValueFactoryMap.java:39) at org.apache.batik.css.svg.SVGValueFactoryMap.init(SVGValueFactoryMap.java:39) at org.apache.batik.css.svg.SVGValueFactoryMap.init(SVGValueFactoryMap.java:32) at org.apache.batik.dom.svg.SVGDOMImplementation.init(SVGDOMImplementation.java:88) at org.apache.batik.dom.svg.SVGDOMImplementation.clinit(SVGDOMImplementation.java:76) at org.apache.batik.dom.svg.SAXSVGDocumentFactory.init(SAXSVGDocumentFactory.java:66) at org.apache.fop.image.analyser.SVGReader.loadImage(Unknown Source) at org.apache.fop.image.analyser.SVGReader.verifySignature(Unknown Source) at org.apache.fop.image.analyser.ImageReaderFactory.Make(Unknown Source) at org.apache.fop.image.FopImageFactory.Make(Unknown Source) at org.apache.fop.fo.flow.ExternalGraphic.layout(Unknown Source) at org.apache.fop.fo.flow.TableCell.layout(Unknown Source) at org.apache.fop.fo.flow.TableRow.layout(Unknown Source) at org.apache.fop.fo.flow.TableBody.layout(Unknown Source) at org.apache.fop.fo.flow.Table.layout(Unknown Source) at org.apache.fop.fo.flow.Block.layout(Block.java:256) at org.apache.fop.fo.flow.Flow.layout(Unknown Source) at org.apache.fop.fo.flow.Flow.layout(Unknown Source) at org.apache.fop.fo.pagination.PageSequence.format(Unknown Source) at org.apache.fop.apps.StreamRenderer.render(Unknown Source) at org.apache.fop.fo.FOTreeBuilder.endElement(Unknown Source) at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source) at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source) at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source) at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) at org.apache.fop.apps.Driver.render(Unknown Source) at org.apache.fop.apps.Driver.run(Unknown Source) we don't use any svg graphics and a x-server is installed on the system. Does anyone know why the error occurs only sometimes and what we can do? greets thmarx - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: fop error - Too many open files
usando ulimit -n 64000 aumentamos o numero de arquivos, resolve solve the problem J.Pietschmann wrote: Elton Simões Baptista wrote: [EMAIL PROTECTED] dbf]$ [EMAIL PROTECTED] dbf]$ fop.sh cat-scania.fo -pdf cat-scania.pdf Your JRE seems to have difficulties with disposing unused File objects in time. Well, maybe FOP has indeed an object leak, it's quite hard to tell from a quick glance at the code. Some possible solutions: - Track down the part in the JPG reader after which the all data has been read, and close the connection explicitely - Convert the images into another format, like GIF or BMP, which is processed differently and wont have the same problem. In particular you'll probably get quite different effects if you use GIF images. - Increase the number of file handles for your user processes, or the hard file handle limit in the kernel. Reboot. - Render the document piecewise, and use another PDF library like iText to concat the pieces. J.Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Elton Simões Baptista elton at cipec com br Cipec Autopeças Ltda Fone: +55 19 3834.9817 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: fop error - Too many open files
Elton Simões Baptista wrote: [EMAIL PROTECTED] dbf]$ [EMAIL PROTECTED] dbf]$ fop.sh cat-scania.fo -pdf cat-scania.pdf Your JRE seems to have difficulties with disposing unused File objects in time. Well, maybe FOP has indeed an object leak, it's quite hard to tell from a quick glance at the code. Some possible solutions: - Track down the part in the JPG reader after which the all data has been read, and close the connection explicitely - Convert the images into another format, like GIF or BMP, which is processed differently and wont have the same problem. In particular you'll probably get quite different effects if you use GIF images. - Increase the number of file handles for your user processes, or the hard file handle limit in the kernel. Reboot. - Render the document piecewise, and use another PDF library like iText to concat the pieces. J.Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: FOP Error
Title: Message Hi, Possible reasons (I know) to get this error dialog 1. Check the root element in the xml and also verify whether the xsl:templatetag name is correct 2. You will get this error if the rendering process is stop abruptly before completion. regards, Elango TR -Original Message-From: Jirole, Amar [mailto:[EMAIL PROTECTED]Sent: Thursday, September 16, 2004 4:38 AMTo: '[EMAIL PROTECTED]'Subject: FOP Error I am trying to run fop code very similar to ExampleObj2Pdf attached along with documentation but I get following error when i try to open the pdf file generated. Any idea what might be going wrong? This error is not there in FAQ. Thanks -Amar This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information.If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email or any action taken in reliance on this e-mail is strictly prohibited and may be unlawful. Visit us at http://www.cognizant.comOutlook.bmp
Re: FOP [ERROR] null
See comments below Hello, Can I get any help on the following error message: [ERROR] null All I could find is that my FO file is not valid, but as far as I can see it is... Try turning debug on, FOP should then give more information on the cause of the problem (-d on command line) Also when there is no FOP schema provided on the apache web site (the link points to the faq). RenderX provides a DTD on their website http://www.renderx.com/ but there is no official DTD, as FO cannot be fully validated using a DTD/Schema alone. Can I get an hold on this schema to validate my source ? Regards, Boris _ Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FOP [ERROR] null
Boris Rousseau wrote: Can I get any help on the following error message: [ERROR] null All I could find is that my FO file is not valid, but as far as I can see it is... Also when there is no FOP schema provided on the apache web site (the link points to the faq). You can get it from cvs, see http://cvs.apache.org/viewcvs.cgi/xml-fop/docs/foschema. Can I get an hold on this schema to validate my source ? Validation is at our todo list, but your request is important, I'll add it as user enhancement request to bugzilla. -- Oleg Tkachenko eXperanto team Multiconn Technologies, Israel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FOP [ERROR] null
Boris Rousseau wrote: Can I get any help on the following error message: [ERROR] null While there is a variety of reasons, this is most often caused by a master-reference missing or misspelled in a conditional-page-master-reference. Check this first. J.Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FOP error with xsl:copy-of .../
There are no chapter_title or sub formatting objects in xsl-fo, you have to transform it in xslt to fo objects, like fo:inline rather than just copying them to the fo. [EMAIL PROTECTED] wrote: Hi, I am attaching the test xsl,xml and the java files. The problem is that the description of any node could have tags and text mixed. If I use xsl:value-of (with FOP), I get only the text and when I use xsl:copy-of (without FOP embeded), I get the desired result, but with FOP I am getting 'error 10231' I have tried everything that I could think of and could not come up with the correct stylesheet. I truly could use your help I am anxiously waiting for a solution. Thank you so much in advance. Norm --- ERROR - ERROR 10231 [fop ] (): Unknown formatting object null^chapter_title Exception in thread main org.apache.fop.apps.FOPException: java.lang.NullPoin erException at org.apache.fop.apps.Driver.render(Driver.java:486) at test1.main(test1.java:102) test.xml -- ?xml version=1.0 encoding=iso-8859-1? ?xml-stylesheet type='text/xsl' href='test.xsl'? document id=DOCUMENT 810-005_103 chapter id=test chapter_titleTesting Chapter sub3/sub/chapter_title /chapter /document -- test.xsl --- xsl:stylesheet xmlns:xsl=http://www.w3.org/1999/XSL/Transform; version=1.0 xmlns:fo=http://www.w3.org/1999/XSL/Format; xsl:template match=document fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format; fo:layout-master-set fo:simple-page-master page-width=200mm master-name=Page1 page-height=280mm margin-top=10mm margin-bottom=10mm margin-left=20mm margin-right=20mm fo:region-body margin-top=0mm margin-bottom=10mm margin-left=0mm margin-right=0mm/ /fo:simple-page-master fo:page-sequence-master master-name=PS1 fo:single-page-master-reference master-name=Page1/ /fo:page-sequence-master /fo:layout-master-set fo:page-sequence master-reference=Page1 fo:flow flow-name=xsl-region-body xsl:apply-templates/ /fo:flow /fo:page-sequence /fo:root /xsl:template xsl:template match=document/chapter/chapter_title fo:block space-after=3mm font-size=14pt text-align=center break-before=page break-after=page xsl:copy-of select=./ /fo:block /xsl:template /xsl:stylesheet --- test.java file just the main() public static void main () { File xmlFile=new File(test.xml); File xslFile=new File(test.xsl); File pdfFile=new File(test.pdf); Logger log = null; if(log == null) { Hierarchy hierarchy = Hierarchy.getDefaultHierarchy(); log = hierarchy.getLoggerFor(fop); log.setPriority(Priority.WARN); } FileOutputStream OutFile = new FileOutputStream(pdfFile); ByteArrayOutputStream out = new ByteArrayOutputStream(); Driver driver=new Driver(); driver.setLogger(log); driver.setRenderer(Driver.RENDER_PDF); InputHandler ih=new XSLTInputHandler(xmlFile,xslFile); XMLReader p=ih.getParser(); driver.setOutputStream(OutFile); driver.render(p, ih.getInputSource()); OutFile.close(); } }//main __ Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with [EMAIL PROTECTED] http://shopnow.netscape.com/ Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ -- Oleg Tkachenko Multiconn International, Israel
Re: FOP error with xsl:copy-of .../
Hi Oleg, I am new to xsl-fo. I thought I was doing the xsl-fo transformation correctly. Will you PLEASE explaine me how I should do this? you have to transform it in xslt to fo objects, like fo:inline rather than just copying them to the fo. Thank you Norm [EMAIL PROTECTED] wrote: Hi, I am attaching the test xsl,xml and the java files. The problem is that the description of any node could have tags and text mixed. If I use xsl:value-of (with FOP), I get only the text and when I use xsl:copy-of (without FOP embeded), I get the desired result, but with FOP I am getting 'error 10231' I have tried everything that I could think of and could not come up with the correct stylesheet. I truly could use your help I am anxiously waiting for a solution. Thank you so much in advance. Norm --- ERROR - ERROR 10231 [fop ] (): Unknown formatting object null^chapter_title Exception in thread main org.apache.fop.apps.FOPException: java.lang.NullPoin erException at org.apache.fop.apps.Driver.render(Driver.java:486) at test1.main(test1.java:102) test.xml -- ?xml version=1.0 encoding=iso-8859-1? ?xml-stylesheet type='text/xsl' href='test.xsl'? document id=DOCUMENT 810-005_103 chapter id=test chapter_titleTesting Chapter sub3/sub/chapter_title /chapter /document -- test.xsl --- xsl:stylesheet xmlns:xsl=http://www.w3.org/1999/XSL/Transform; version=1.0 xmlns:fo=http://www.w3.org/1999/XSL/Format; xsl:template match=document fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format; fo:layout-master-set fo:simple-page-master page-width=200mm master-name=Page1 page-height=280mm margin-top=10mm margin-bottom=10mm margin-left=20mm margin-right=20mm fo:region-body margin-top=0mm margin-bottom=10mm margin-left=0mm margin-right=0mm/ /fo:simple-page-master fo:page-sequence-master master-name=PS1 fo:single-page-master-reference master-name=Page1/ /fo:page-sequence-master /fo:layout-master-set fo:page-sequence master-reference=Page1 fo:flow flow-name=xsl-region-body xsl:apply-templates/ /fo:flow /fo:page-sequence /fo:root /xsl:template xsl:template match=document/chapter/chapter_title fo:block space-after=3mm font-size=14pt text-align=center break-before=page break-after=page xsl:copy-of select=./ /fo:block /xsl:template /xsl:stylesheet --- test.java file just the main() public static void main () { File xmlFile=new File(test.xml); File xslFile=new File(test.xsl); File pdfFile=new File(test.pdf); Logger log = null; if(log == null) { Hierarchy hierarchy = Hierarchy.getDefaultHierarchy(); log = hierarchy.getLoggerFor(fop); log.setPriority(Priority.WARN); } FileOutputStream OutFile = new FileOutputStream(pdfFile); ByteArrayOutputStream out = new ByteArrayOutputStream(); Driver driver=new Driver(); driver.setLogger(log); driver.setRenderer(Driver.RENDER_PDF); InputHandler ih=new XSLTInputHandler(xmlFile,xslFile); XMLReader p=ih.getParser(); driver.setOutputStream(OutFile); driver.render(p, ih.getInputSource()); OutFile.close(); } }//main __ Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with [EMAIL PROTECTED] http://shopnow.netscape.com/ Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
Re: FOP error with xsl:copy-of .../
[EMAIL PROTECTED] wrote: I am new to xsl-fo. I thought I was doing the xsl-fo transformation correctly. Will you PLEASE explaine me how I should do this? Would you ask on rec.aviation Would you PLEASE teach me how to fly aircraft (by email)? Search the web for formatting object tutorial and variants, there are some available. There is also the XSL FAQ http://www.dpawson.co.uk/, but given your activity on the XSL list you already discovered it. Questions regarding transformation of arbitrary XML into anything including XSLFO are best asked on the XSL list anyway. J.Pietschmann