Re: Java Result: 2 Why?
(Comments inline...) On 04.05.2006 13:48:05 David wrote: Dear members, I am getting problmes when getting generating the PDF file from using FOP. I am using DocBook, vía Ant: presetdef name=docbook java classname=com.icl.saxon.StyleSheet fork=true dir=${doc.ref.src.dir} classpath fileset dir=${docbook.dir}/lib include name=**/*.jar / /fileset pathelement location=${build.testclasses.dir}/resource/config / /classpath /java /presetdef echo level=info message=${message.docbook.generatingTmpFile} / docbook failonerror=true arg value=-o / arg value=${build.doc.ref.pdf.dir}/docbook_fop.tmp / arg value=index.xml / arg value=styles/fopdf.xsl / /docbook echo level=info message=${message.docbook.generatingPdfFile} / docbook classname=org.apache.fop.apps.Fop Add this to get more error info: arg value=-d / arg value=${build.doc.ref.pdf.dir}/docbook_fop.tmp / arg value=${build.doc.ref.pdf.dir}/${name}.pdf / /docbook The temporal file generation is done, but after that I get the following error: Buildfile: P:\LRA\build.xml check-build-doc: doc2pdf: [echo] INFO(lra): Generating intermediate file... [docbook] Making portrait pages on A4 paper (210mmx297mm) [echo] INFO(lra): Generating pdf file... [docbook] [INFO] Using com.icl.saxon.aelfred.SAXDriver as SAX2 Parser [docbook] [INFO] FOP 0.20.5 [docbook] [INFO] Using com.icl.saxon.aelfred.SAXDriver as SAX2 Parser [docbook] [INFO] building formatting object tree [docbook] [INFO] setting up fonts [docbook] [INFO] [1] [docbook] [INFO] [2] [docbook] [INFO] [1] [docbook] [INFO] [2] [docbook] [INFO] Parsing of document complete, stopping renderer [docbook] [ERROR] null [docbook] Java Result: 2 BUILD SUCCESSFUL Total time: 5 seconds so, the PDF file is not generated. I am trying to get more information about the error, but I have no find the way. I have added, the line on my log4j.properties file, withut success: org.apache.fop.apps.Fop = DEBUG That doesn't work because you're calling FOP's command-line in which case Ant simply captures the console output from FOP and redirects it to it own logger. BTW, there's a Fop Ant Task: http://xmlgraphics.apache.org/fop/0.20.5/anttask.html so, I don't know what is going on, at the begining I thught it is a problem with some docbook syntax, but it doesn't because for example if I change the name of the URL on the ulink element then it fails, so it should be something extrange, but I don't know. I am using the docbook library from: http://static.springframework.org/spring/files/docbook-reference-libs.zip Thanks, in advance for any inputs, David Jeremias Maerki - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: conditional page break
Hi, Carrying on from this thread: http://www.nabble.com/forum/ViewTopic.jtp?topic=725743tview=dump#a19023 05 Where the answer to stopping a block spanning a page break but actually go onto the next page if there's not enough room to render the whole block, instead of spanning the page break, was:- !-- conditional page break blag -- fo:block-container height=4cm fo:block fo:leader leader-length=0pt/ /fo:block /fo:block-container fo:block space-before=-4cm/ !-- end conditional page break blag -- !-- Real stuff goes here -- ... (Cool trick by the way and works in the latest trunk of FOP.) But it does depend on setting the height to what you guess is going to be the max rendered height of a block Is there a keep-together type of thing that would force a block not to straddle a page break? Cheers Karl 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. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: vertical-align 50% does not work?
On Friday 05 May 2006 15:45, Dirk Bromberg wrote: Hi all, fo:inline font-size=12pt vertical-align=50%.../fo:inline does result as: ERROR org.apache.fop.fo.PropertyList - No conversion defined 50%; property:'vertical-align' but the website: http://xmlgraphics.apache.org/fop/compliance.html#fo-property-vertica l-align says: Trunk: yes I'm using 0.92 release. Had a quick look at the code and the vertical-align shorthand expansion does indeed not support percentages. You could try to use the expanded properties instead (see XSL-FO spec 7.29.22). In this particular case vertical-align=50% is suppose to be expanded into: alignment-baseline=baseline alignment-adjust=50% baseline=shift=baseline dominant-baseline=auto This actually means under 'usual circumstances' vertical-align=50% is equivalent to alignment-adjust=50%. So try that and let us know if it fixed it. Thanks Dirk Manuel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Error while creating font metric file
Hi, I am trying to create font metrics file for FOP Trunk. I use the following command: java org.apache.fop.fonts.apps.TTFReader C:\myfont\times.ttf C:\FopTrunk\conf\my_new_font.xml In my CLASSPATH I have: C:\FopTrunk\build\fop.jar;C:\FopTrunk\lib\avalon-framework.jar;C:\FopTrunk\lib\xml-apis.jar;C:\FopTrunk\lib\xercesImpl.jar;C:\FopTrunk\lib\xalan.jar and C:\myfont\times.ttf exists. I get the following error: Exception in thread main java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory at org.apache.fop.fonts.apps.TTFReader.main(TTFReader.java:109) Where can be problem? And is there any possibility then to copy text from PDF? Thanks, Pavel Tyl -- View this message in context: http://www.nabble.com/Error-while-creating-font-metric-file-t1563275.html#a4245353 Sent from the FOP - Users forum at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Java Result: 2 Why?
Dear Glen Mazza and others,Glen Mazza [EMAIL PROTECTED] wrote:More detective work seems needed. Have you tried to create the absolutely most minimal Docbook document possible, to see if the error still occurs? This would help determine if the problem is in the text (in which case, you can slowly zoom in on the problematic XML by adding more of your original text in) or your Docbook setup.I did that, it is not my first docbook, more precisly I have problems with only one chapter of my document. The problem doesn't comes with the docbook syntax, because when I have isolated the paragraph, I was surpised that simply changing a particular URL it get the error. I suspect that it is a problem about fitting into page the text and not a particular docbook syntax. If you want I can sent you the original document, if we find the problem then I will write into the mailing list the result of our investigation, :-)I get perfectly the HTML document, my problem comes with the PDF document. I have tried to convert the HTML document into PDF using Adobe Acrobat Professional and it works.Also, I think there is a fop.extensions parameter[1] that needs to be set for Docbook when you are using our processor. The Docbook-Apps mailing list may be able to help you more on this topic, unless someone else here also knows.on Docbook there is a clear message for preventing posting messages related with style and other companions tools like this. On my case, I guess there is no a docbook question, because I can generates the HTML file.Thanks,David Yahoo! Messenger with Voice. Make PC-to-Phone Calls to the US (and 30+ countries) for 2¢/min or less.
Re: Error while creating font metric file
You shoud you use some like: java -cp build\fop.jar;lib\avalon-framework-4.2.0.jar;lib\commons-logging-1.0.4.jar;lib\commons-io-1.1.jar org.apache.fop.fonts.apps.TTFReader ?? the jars have version numbers in... Dirk kralik wrote: Hi, I am trying to create font metrics file for FOP Trunk. I use the following command: java org.apache.fop.fonts.apps.TTFReader C:\myfont\times.ttf C:\FopTrunk\conf\my_new_font.xml In my CLASSPATH I have: C:\FopTrunk\build\fop.jar;C:\FopTrunk\lib\avalon-framework.jar;C:\FopTrunk\lib\xml-apis.jar;C:\FopTrunk\lib\xercesImpl.jar;C:\FopTrunk\lib\xalan.jar and C:\myfont\times.ttf exists. I get the following error: Exception in thread main java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory at org.apache.fop.fonts.apps.TTFReader.main(TTFReader.java:109) Where can be problem? And is there any possibility then to copy text from PDF? Thanks, Pavel Tyl -- View this message in context: http://www.nabble.com/Error-while-creating-font-metric-file-t1563275.html#a4245353 Sent from the FOP - Users forum at Nabble.com. - 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: vertical-align 50% does not work?
It is working. Thanks. Dirk Manuel Mall wrote: On Friday 05 May 2006 15:45, Dirk Bromberg wrote: Hi all, fo:inline font-size=12pt vertical-align=50%.../fo:inline does result as: ERROR org.apache.fop.fo.PropertyList - No conversion defined 50%; property:'vertical-align' but the website: http://xmlgraphics.apache.org/fop/compliance.html#fo-property-vertica l-align says: Trunk: yes I'm using 0.92 release. Had a quick look at the code and the vertical-align shorthand expansion does indeed not support percentages. You could try to use the expanded properties instead (see XSL-FO spec 7.29.22). In this particular case vertical-align=50% is suppose to be expanded into: alignment-baseline=baseline alignment-adjust=50% baseline=shift=baseline dominant-baseline=auto This actually means under 'usual circumstances' vertical-align=50% is equivalent to alignment-adjust=50%. So try that and let us know if it fixed it. Thanks Dirk Manuel - 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: vertical-align 50% does not work?
Now I've seen that on XEP there is a property to aviod the shift of the normal text when there is a piec of super text (Line gets heigher...) |* http://www.stylusstudio.com/api/fop-0.20.5/org/apache/fop/fo/properties/DominantBaseline.htm#NO_CHANGE*|line-stacking-strategy=max-height line-height-shift-adjustment=disregard-shifts is there a way to get some text as super text 50% and not increase the line-height and align of the other text...? Thanks Dirk Dirk Bromberg wrote: It is working. Thanks. Dirk Manuel Mall wrote: On Friday 05 May 2006 15:45, Dirk Bromberg wrote: Hi all, fo:inline font-size=12pt vertical-align=50%.../fo:inline does result as: ERROR org.apache.fop.fo.PropertyList - No conversion defined 50%; property:'vertical-align' but the website: http://xmlgraphics.apache.org/fop/compliance.html#fo-property-vertica l-align says: Trunk: yes I'm using 0.92 release. Had a quick look at the code and the vertical-align shorthand expansion does indeed not support percentages. You could try to use the expanded properties instead (see XSL-FO spec 7.29.22). In this particular case vertical-align=50% is suppose to be expanded into: alignment-baseline=baseline alignment-adjust=50% baseline=shift=baseline dominant-baseline=auto This actually means under 'usual circumstances' vertical-align=50% is equivalent to alignment-adjust=50%. So try that and let us know if it fixed it. Thanks Dirk Manuel - 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Java Result: 2 Why?
Jeremias Maerki,Concerning to the ant task I am directly invoking java, do you think gain something invoking it via ant?Greate, the-d option gives a little more details, thanks, but no so much from the user point of view. I get the following output:Buildfile: P:\LRA\build.xml check-build-doc: doc2pdf: [echo] INFO(lra): Generating intermediate file... [docbook] Making portrait pages on A4 paper (210mmx297mm) [echo] INFO(lra): Generating pdf file... [docbook] [DEBUG] Input mode: [docbook] [DEBUG] FO [docbook] [DEBUG] fo input file: P:\LRA\build\doc\pdf\docbook_fop.tmp [docbook] [DEBUG] Output mode: [docbook] [DEBUG] pdf [docbook] [DEBUG] output file: P:\LRA\build\doc\pdf\lra.pdf [docbook] [DEBUG] OPTIONS [docbook] [DEBUG] no user configuration file is used [default] [docbook] [DEBUG] debug mode on [docbook] [DEBUG] dump configuration [docbook] [DEBUG] quiet mode on [docbook] [INFO] Using com.icl.saxon.aelfred.SAXDriver as SAX2 Parser [docbook] [INFO] base directory: file:/P:/LRA/build/doc/pdf/ [docbook] [INFO] FOP 0.20.5 [docbook] [INFO] Using com.icl.saxon.aelfred.SAXDriver as SAX2 Parser [docbook] [INFO] building formatting object tree [docbook] [INFO] setting up fonts [docbook] [INFO] [1] [docbook] [DEBUG] Last page-sequence produced 1 pages. [docbook] [INFO] [2] [docbook] [INFO] [3] [docbook] [DEBUG] Last page-sequence produced 2 pages. [docbook] [INFO] [4] (blank) [docbook] [INFO] [1] [docbook] [INFO] [2] [docbook] [INFO] [3] [docbook] [DEBUG] Last page-sequence produced 3 pages. [docbook] [INFO] [4] [docbook] [INFO] [5] [docbook] [INFO] [6] [docbook] [INFO] [7] [docbook] [INFO] [8] [docbook] [INFO] [9] [docbook] [INFO] [10] [docbook] [INFO] [11] [docbook] [INFO] [12] [docbook] [INFO] [13] [docbook] [DEBUG] Last page-sequence produced 10 pages. [docbook] [INFO] [14] [docbook] [INFO] [15] [docbook] [INFO] [16] [docbook] [DEBUG] Last page-sequence produced 3 pages. [docbook] [INFO] [17] [docbook] [INFO] [18] [docbook] [INFO] [19] [docbook] [WARNING] table-layout=auto is not supported, using fixed! [docbook] [INFO] [20] [docbook] [INFO] [21] [docbook] [DEBUG] Last page-sequence produced 5 pages. [docbook] [INFO] [22] [docbook] [INFO] [23] [docbook] [INFO] Parsing of document complete, stopping renderer [docbook] [DEBUG] Initial heap size: 747Kb [docbook] [DEBUG] Current heap size: 9181Kb [docbook] [DEBUG] Total memory used: 8434Kb [docbook] [DEBUG] Memory use is indicative; no GC was performed [docbook] [DEBUG] These figures should not be used comparatively [docbook] [DEBUG] Total time used: 2422ms [docbook] [DEBUG] Pages rendered: 26 [docbook] [DEBUG] Avg render time: 93ms/page [docbook] [ERROR] null [docbook] org.apache.fop.apps.FOPException [docbook] at org.apache.fop.apps.CommandLineStarter.run(CommandLineStarter.java:111) [docbook] at org.apache.fop.apps.Fop.main(Fop.java:62) [docbook] - [docbook] java.lang.NullPointerException [docbook] at org.apache.fop.layout.LineArea.addText(LineArea.java:855) [docbook] at org.apache.fop.fo.FOText.addRealText(FOText.java:278) [docbook] at org.apache.fop.fo.FOText.addText(FOText.java:252) [docbook] at org.apache.fop.fo.FOText.layout(FOText.java:161) [docbook] at org.apache.fop.fo.FObjMixed.layout(FObjMixed.java:139) [docbook] at org.apache.fop.fo.flow.ListItemBody.layout(ListItemBody.java:118) [docbook] at org.apache.fop.fo.flow.ListItem.layout(ListItem.java:203) [docbook] at org.apache.fop.fo.flow.ListBlock.layout(ListBlock.java:201) [docbook] at org.apache.fop.fo.flow.Block.layout(Block.java:257) [docbook] at org.apache.fop.fo.flow.Block.layout(Block.java:257) [docbook] at org.apache.fop.fo.flow.Block.layout(Block.java:257) [docbook] at org.apache.fop.fo.flow.AbstractFlow.layout(AbstractFlow.java:154) [docbook] at org.apache.fop.fo.flow.AbstractFlow.layout(AbstractFlow.java:110) [docbook] at org.apache.fop.fo.pagination.PageSequence.makePage(PageSequence.java:400) [docbook] at org.apache.fop.fo.pagination.PageSequence.format(PageSequence.java:338) [docbook] at org.apache.fop.apps.StreamRenderer.render(StreamRenderer.java:262) [docbook] at org.apache.fop.fo.FOTreeBuilder.endElement(FOTreeBuilder.java:223) [docbook] at com.icl.saxon.aelfred.SAXDriver.endElement(SAXDriver.java:792) [docbook] at com.icl.saxon.aelfred.XmlParser.parseETag(XmlParser.java:1133) [docbook] at com.icl.saxon.aelfred.XmlParser.parseContent(XmlParser.java:1217) [docbook] at com.icl.saxon.aelfred.XmlParser.parseElement(XmlParser.java:1037) [docbook] at com.icl.saxon.aelfred.XmlParser.parseContent(XmlParser.java:1222) [docbook] at com.icl.saxon.aelfred.XmlParser.parseElement(XmlParser.java:1037) [docbook] at com.icl.saxon.aelfred.XmlParser.parseDocument(XmlParser.java:510) [docbook] at com.icl.saxon.aelfred.XmlParser.doParse(XmlParser.java:163) [docbook] at com.icl.saxon.aelfred.SAXDriver.parse(SAXDriver.java:320) [docbook] at
Re: vertical-align 50% does not work?
On Friday 05 May 2006 20:09, Dirk Bromberg wrote: Now I've seen that on XEP there is a property to aviod the shift of the normal text when there is a piec of super text (Line gets heigher...) |* http://www.stylusstudio.com/api/fop-0.20.5/org/apache/fop/fo/propert ies/DominantBaseline.htm#NO_CHANGE*|line-stacking-strategy=max-heigh t line-height-shift-adjustment=disregard-shifts is there a way to get some text as super text 50% and not increase the line-height and align of the other text...? line-height-shift-adjustment is not yet implemented. Actually as far as I can recall you are the first one mentioning this property on this list. However, I believe setting line-stacking-strategy=font-height on the enclosing block may do the trick depending on the complexity of what you doing. Thanks Dirk snip/ Manuel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: vertical-align 50% does not work?
Manuel Mall wrote: On Friday 05 May 2006 20:09, Dirk Bromberg wrote: Now I've seen that on XEP there is a property to aviod the shift of the normal text when there is a piec of super text (Line gets heigher...) |* http://www.stylusstudio.com/api/fop-0.20.5/org/apache/fop/fo/propert ies/DominantBaseline.htm#NO_CHANGE*|line-stacking-strategy=max-heigh t line-height-shift-adjustment=disregard-shifts is there a way to get some text as super text 50% and not increase the line-height and align of the other text...? line-height-shift-adjustment is not yet implemented. Actually as far as I can recall you are the first one mentioning this property on this list. However, I believe setting line-stacking-strategy=font-height on the enclosing block may do the trick depending on the complexity of what you doing. Yes, that's it :-) Thanks! Dirk Thanks Dirk snip/ Manuel - 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: conditional page break
Are you looking for keep-together.within-page=always or do I misunderstand what you're after? On 05.05.2006 09:07:07 Karl Roberts wrote: Hi, Carrying on from this thread: http://www.nabble.com/forum/ViewTopic.jtp?topic=725743tview=dump#a19023 05 Where the answer to stopping a block spanning a page break but actually go onto the next page if there's not enough room to render the whole block, instead of spanning the page break, was:- !-- conditional page break blag -- fo:block-container height=4cm fo:block fo:leader leader-length=0pt/ /fo:block /fo:block-container fo:block space-before=-4cm/ !-- end conditional page break blag -- !-- Real stuff goes here -- ... (Cool trick by the way and works in the latest trunk of FOP.) But it does depend on setting the height to what you guess is going to be the max rendered height of a block Is there a keep-together type of thing that would force a block not to straddle a page break? Jeremias Maerki - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
preliminary report on thesis and memory use
About a month ago I asked if FOP could handle a thesis about 100 pages long with a table of contents at the beginning. I was told the best way to answer the question was to write the stylesheets to convert the thesis to FO and use FOP to convert it. It obviously took me a little bit of time to do so. At this point the body of the thesis is around 60 pages long. There is then a 40 page table. The table of contents only has to reference to page 60; after that there are no more references. I ran FOP on my 400 MHZ machine loaded with linux. I am using FOP version 0.91beta and java version 1.4.1. It took me 47 seconds to process the document and I encountered no memory problems. This test is preliminary because there is one more appendix that will contain many, many graphics, and the table of contents will point to these graphics. Paul -- *Paul Tremblay * [EMAIL PROTECTED]* - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]