Re: Border problem with dynamic content
On Tue, Aug 19, 2008 at 9:06 AM, Chris Bowditch [EMAIL PROTECTED] wrote: You are going to need to put the border on fo:region-body and make the fo:region-body extend to the edge of the page. Strictly speaking this is not allowed by the XSL-FO specification but I believe FOP allows it. (hoping this does not come too late) Borders on regions should work, but relaxed validation must be turned on (with the -r option on the command line, for example) otherwise the validation error prevents the creation of the pdf. For the other devs: what if I modify the validation message concerning borders / paddings on regions so that it says something like this is not strictly valid, but if you really need it ...? HTH Luca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
FOP 0.93 vs 0.94 vs 0.95
Hello I have an FO file and I want to use it to generate a PDF File. When I use FOP 0.93 by command line, everything works fine. A PDF file is generated correctly. This PDF file contains a table, text and 3 checkboxes. When I use FOP 0.93 using Java API, the PDF is generated, no error is generated but the checkboxes are not generated. They simply does not appear. With FOP 0.94 using Java API, the result is the same. With FOP 0.95, using Java API, the PDF is not generated. The following error is displayed: Exception in thread Thread-3 org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.StackOverflowError) at org.eclipse.swt.SWT.error(SWT.java:3374) at org.eclipse.swt.SWT.error(SWT.java:3297) at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:178) at org.eclipse.swt.widgets.Display.syncExec(Display.java:3763) at composite.NouvelleLettreStructuree$6$1$1.run(NouvelleLettreStructuree.java:646) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.StackOverflowError at sun.misc.FloatingDecimal.dtoa(Unknown Source) at sun.misc.FloatingDecimal.init(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.properties.PercentLength.toString(PercentLength.java:121) at java.lang.String.valueOf(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.flow.table.TableColumn.toString(TableColumn.java:233) Any idea on how can I can generate the PDF correctly using FOP API? Thanks Regards.
Re: FOP 0.93 vs 0.94 vs 0.95
Hi, can you post your FO or your stylesheet? PercentLength.toString Seems to be a problem with that line. Do you use percent somewhere? Regards, ToM Hello I have an FO file and I want to use it to generate a PDF File. When I use FOP 0.93 by command line, everything works fine. A PDF file is generated correctly. This PDF file contains a table, text and 3 checkboxes. When I use FOP 0.93 using Java API, the PDF is generated, no error is generated but the checkboxes are not generated. They simply does not appear. With FOP 0.94 using Java API, the result is the same. With FOP 0.95, using Java API, the PDF is not generated. The following error is displayed: Exception in thread Thread-3 org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.StackOverflowError) at org.eclipse.swt.SWT.error(SWT.java:3374) at org.eclipse.swt.SWT.error(SWT.java:3297) at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:178) at org.eclipse.swt.widgets.Display.syncExec(Display.java:3763) at composite.NouvelleLettreStructuree$6$1$1.run(NouvelleLettreStructuree.java:646) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.StackOverflowError at sun.misc.FloatingDecimal.dtoa(Unknown Source) at sun.misc.FloatingDecimal.init(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.properties.PercentLength.toString(PercentLength.java:121) at java.lang.String.valueOf(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.flow.table.TableColumn.toString(TableColumn.java:233) Any idea on how can I can generate the PDF correctly using FOP API? Thanks Regards. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FOP 0.93 vs 0.94 vs 0.95
Hello I solved the checkbox problem. It was a problem of the FO file. However, I cannot understand why it doesn't work with FOP 0.95. Thanks Regards On Mon, Aug 25, 2008 at 1:04 PM, Tobias van Treeck [EMAIL PROTECTED]wrote: Hi, can you post your FO or your stylesheet? PercentLength.toString Seems to be a problem with that line. Do you use percent somewhere? Regards, ToM Hello I have an FO file and I want to use it to generate a PDF File. When I use FOP 0.93 by command line, everything works fine. A PDF file is generated correctly. This PDF file contains a table, text and 3 checkboxes. When I use FOP 0.93 using Java API, the PDF is generated, no error is generated but the checkboxes are not generated. They simply does not appear. With FOP 0.94 using Java API, the result is the same. With FOP 0.95, using Java API, the PDF is not generated. The following error is displayed: Exception in thread Thread-3 org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.StackOverflowError) at org.eclipse.swt.SWT.error(SWT.java:3374) at org.eclipse.swt.SWT.error(SWT.java:3297) at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:178) at org.eclipse.swt.widgets.Display.syncExec(Display.java:3763) at composite.NouvelleLettreStructuree$6$1$1.run(NouvelleLettreStructuree.java:646) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.StackOverflowError at sun.misc.FloatingDecimal.dtoa(Unknown Source) at sun.misc.FloatingDecimal.init(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.properties.PercentLength.toString(PercentLength.java:121) at java.lang.String.valueOf(Unknown Source) at java.lang.StringBuffer.append(Unknown Source) at org.apache.fop.fo.flow.table.TableColumn.toString(TableColumn.java:233) Any idea on how can I can generate the PDF correctly using FOP API? Thanks Regards. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FOP 0.93 vs 0.94 vs 0.95
On Aug 25, 2008, at 13:42, Paulo Carvalho wrote: Hi I solved the checkbox problem. It was a problem of the FO file. However, I cannot understand why it doesn't work with FOP 0.95. That was due to a regression, where PercentLength.toString() indirectly called itself (a consequence of using Object.toString() instead of Property.getString()) I'm not entirely certain, but it seems like the fix never made it into 0.95. IIC, this issue should not exist in FOP Trunk anymore. Can you verify this, or send us the related FO, so we can verify ourselves? Thanks Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
0.95 - Printing a string and aligning the decimal points
Friends, Existing Code in my XML file (the decimal points are aligned when using Courier font): euro-tax-msg5Quebec Native Seal Tax 15.42/euro-tax-msg5 euro-tax-msg6BIG UPPER CASE TAX INO 439.59/euro-tax-msg6 -- My XSL that prints (using Arial font): fo:block white-space-collapse=false linefeed-treatment=preserve text-align=start xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg5/ xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg6/ xsl:text#x0A;/xsl:text /fo:block - My Result: Thelkj lk laksjf lkasjd flkajs flkj15.42 Wakadf wlkej salksdjf 349.54 Without creating a table, is there a way to get the text to align left and the digits to align right? I thank you for any suggestions. Jeff
Re: 0.95 - Printing a string and aligning the decimal points
Assuming you can guarantee that there will always be at least two spaces between the text and the digits, could you do something like the following? fo:block white-space-collapse=false linefeed-treatment=preserve text-align-last=justify xsl:text#x0A;/xsl:text xsl:call-template name=split xsl:with-param name=string select=euro-tax-msg5 / /xsl:call-template xsl:text#x0A;/xsl:text xsl:call-template name=split xsl:with-param name=string select=euro-tax-msg6 / /xsl:call-template xsl:text#x0A;/xsl:text /fo:block xsl:template name=split xsl:param name=string / xsl:variable name=first select=substring-before($string,' ') / xsl:variable name=rest select=substring-after($string,' ') / xsl:value-of select=$first /fo:leader/xsl:value-of select=$rest / /xsl:template Steffanina, Jeff [EMAIL PROTECTED] 8/25/2008 1:07 PM Friends, Existing Code in my XML file (the decimal points are aligned when using Courier font): euro-tax-msg5Quebec Native Seal Tax 15.42/euro-tax-msg5 euro-tax-msg6BIG UPPER CASE TAX INO 439.59/euro-tax-msg6 -- My XSL that prints (using Arial font): fo:block white-space-collapse=false linefeed-treatment=preserve text-align=start xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg5/ xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg6/ xsl:text#x0A;/xsl:text /fo:block - My Result: Thelkj lk laksjf lkasjd flkajs flkj15.42 Wakadf wlkej salksdjf 349.54 Without creating a table, is there a way to get the text to align left and the digits to align right? I thank you for any suggestions. Jeff
RE: 0.95 - Printing a string and aligning the decimal points
David, I can't make that guarantee of the space you mentioned. Can I make it more simple if I split the string into Description and Amount as follows (again, my goal is to align the descriptions and the decimal points): euro-tax-msg5Quebec Native Seal Tax/euro-tax-msg5 euro-tax-msg5-amt15.42/euro-tax-msg5-amt euro-tax-msg6BIG UPPER CASE TAX INO/euro-tax-msg6 euro-tax-msg6-amt439.59/euro-tax-msg6-amt -- Jeff From: David Gerdt [mailto:[EMAIL PROTECTED] Sent: Monday, August 25, 2008 2:23 PM To: fop-users@xmlgraphics.apache.org Subject: Re: 0.95 - Printing a string and aligning the decimal points Assuming you can guarantee that there will always be at least two spaces between the text and the digits, could you do something like the following? fo:block white-space-collapse=false linefeed-treatment=preserve text-align-last=justify xsl:text#x0A;/xsl:text xsl:call-template name=split xsl:with-param name=string select=euro-tax-msg5 / /xsl:call-template xsl:text#x0A;/xsl:text xsl:call-template name=split xsl:with-param name=string select=euro-tax-msg6 / /xsl:call-template xsl:text#x0A;/xsl:text /fo:block xsl:template name=split xsl:param name=string / xsl:variable name=first select=substring-before($string,' ') / xsl:variable name=rest select=substring-after($string,' ') / xsl:value-of select=$first /fo:leader/xsl:value-of select=$rest / /xsl:template Steffanina, Jeff [EMAIL PROTECTED] 8/25/2008 1:07 PM Friends, Existing Code in my XML file (the decimal points are aligned when using Courier font): euro-tax-msg5Quebec Native Seal Tax 15.42/euro-tax-msg5 euro-tax-msg6BIG UPPER CASE TAX INO 439.59/euro-tax-msg6 -- My XSL that prints (using Arial font): fo:block white-space-collapse=false linefeed-treatment=preserve text-align=start xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg5/ xsl:text#x0A;/xsl:text xsl:value-of select=./euro-tax-msg6/ xsl:text#x0A;/xsl:text /fo:block - My Result: Thelkj lk laksjf lkasjd flkajs flkj15.42 Wakadf wlkej salksdjf 349.54 Without creating a table, is there a way to get the text to align left and the digits to align right? I thank you for any suggestions. Jeff
I need fo:retrieve-table-marker example or how to implement continued label in FOP-95?
Hi, I am new to FOP and I need to convert FOP-20 to FOP-95. In FOP-20 we used fox:extension continued label for the table header. So if it's 1st page - table header prints Subject. All next pages will have the same table header with Subject cont. printed. How can I do it with latest FOP? Thank you for your help. -- View this message in context: http://www.nabble.com/I-need-fo%3Aretrieve-table-marker-example-or-how-to-implement-continued-label-in-FOP-95--tp19150429p19150429.html Sent from the FOP - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
XSL caching question
In FOP 0.95, I'm using the basic caching method to cache my XSL transformation file, not doing anything fancy with file system monitors or anything for the time being. The first time I run FOP on the server to generate a pdf, it takes 10-20 seconds to generate the pdf because it's loading up the XSL file for the first run. Afterwards it runs in the neighborhood of 500ms per PDF. I was just wondering if there is a way to force the XSL to fully cache statically? This isn't a huge issue as we don't restart our servers all that often but it's just a little thing that's bugging me J Thanks, ___ Brian Trezise Staff Software Engineer IntelliData, Inc 22288 E Princeton Dr aurora, colorado 80018 T: 720.524.4864 [EMAIL PROTECTED]
RE: XSL caching question
Silly me, going to be hard for you guys to answer my question if you don't have a code sample to look at J static { try { cyberTron = TransformerFactory.newInstance(); Config config = (Config) ConfigManager.getInstance().getConfig(Config.class); Source xslt = new StreamSource(new File(config.getXSLTemplateURL())); allSpark = cyberTron.newTemplates(xslt); } catch(Exception e) { logger.error(e); } } ~Brian ___ Brian Trezise Staff Software Engineer IntelliData, Inc 22288 E Princeton Dr aurora, colorado 80018 T: 720.524.4864 [EMAIL PROTECTED] From: Brian Trezise [mailto:[EMAIL PROTECTED] Sent: Monday, August 25, 2008 2:41 PM To: fop-users@xmlgraphics.apache.org Subject: XSL caching question In FOP 0.95, I'm using the basic caching method to cache my XSL transformation file, not doing anything fancy with file system monitors or anything for the time being. The first time I run FOP on the server to generate a pdf, it takes 10-20 seconds to generate the pdf because it's loading up the XSL file for the first run. Afterwards it runs in the neighborhood of 500ms per PDF. I was just wondering if there is a way to force the XSL to fully cache statically? This isn't a huge issue as we don't restart our servers all that often but it's just a little thing that's bugging me J Thanks, ___ Brian Trezise Staff Software Engineer IntelliData, Inc 22288 E Princeton Dr aurora, colorado 80018 T: 720.524.4864 [EMAIL PROTECTED]
Re: FOP 0.93 vs 0.94 vs 0.95
Ok, thank you for your answer. Im gonna try with the FOP trunk and I will let you know. Best regards On Mon, Aug 25, 2008 at 6:24 PM, Andreas Delmelle [EMAIL PROTECTED] wrote: On Aug 25, 2008, at 13:42, Paulo Carvalho wrote: Hi I solved the checkbox problem. It was a problem of the FO file. However, I cannot understand why it doesn't work with FOP 0.95. That was due to a regression, where PercentLength.toString() indirectly called itself (a consequence of using Object.toString() instead of Property.getString()) I'm not entirely certain, but it seems like the fix never made it into 0.95. IIC, this issue should not exist in FOP Trunk anymore. Can you verify this, or send us the related FO, so we can verify ourselves? Thanks Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]