Re: Page numbering, FOP version
Hey John. Try this in the beginning of your xsl: fo:block fo:page-number//fo:page-number-citation ref-id=endofdoc/ /fo:block And this somewhere close to the end. fo:block id=endofdoc/fo:block Claus Nielsen Denmark Dunning, JohnTo: '[EMAIL PROTECTED]' [EMAIL PROTECTED] JDunning@goSP cc: S.com Subject: Page numbering, FOP version 07-01-2002 17:46 Please respond to fop-dev I'm sorry if this topic has been addressed before, but I couldn't find it in the archives -- can FOP render page numbers as page 1/(n[total number of pages])? Also, the index page at xml.apache.org/fop states The latest version of Fop is 0.20.2 and it supports the xsl:fo XSL-FO Version 1.0 W3C Recommendation (with a link to XSL1.0), but the distribution directory lists the download as Fop-0.20.2RC with a date of 29-Sep-2001 (which, when I downloaded it in September, still used the CR syntax). Has this file been updated to use the Rec syntax, or is that available from CVS, or is this a typo? Thanks in advance, John - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Running fop from Java
How does your XML file look ? Claus Nielsen Mitchell, Scott(LIT) To: [EMAIL PROTECTED] S.Mitchell@Liberty cc: -IT.co.ukSubject: Running fop from Java 03-01-2002 11:32 Please respond to fop-dev Hi, I am trying to use jox to take a java bean and create an xml file. With this file, I use fop to convert to a pdf. I get the following error when running the code. Input XSL; Line 1; Column 1 XSL Error: Could not parse Input XML document! XSL Error: SAX Exception org.apache.xalan.xslt.XSLProcessorException: The markup in the document preceding the root element must be well-formed. at org.apache.xalan.xslt.XSLTEngineImpl.error(XSLTEngineImpl.java:1630) at org.apache.xalan.xslt.XSLTEngineImpl.getSourceTreeFromInput(XSLTEngineImpl.j ava:852) at org.apache.xalan.xslt.XSLTEngineImpl.process(XSLTEngineImpl.java:552) at com.wutka.jox.test.TestSer.main(TestSer.java:82) This is the code, the red line is where the error occurs. public class TestSer { public static void main(String[] args) { try { TestBean b = new TestBean(); b.setFoo(5); b.setBar(This is the bar value); b.setThingies(new String[] { Moe, Larry, Curly, Shemp, Curly Joe }); TestSubbean sub = new TestSubbean(); sub.setName(Mark); sub.setAge(35); b.setSub(sub); FileOutputStream fileOut = new FileOutputStream(f:/ProgramFiles/jox/source/com/wutka/jox/test/bean.xml); JOXBeanOutputStream joxOut = new JOXBeanOutputStream(fileOut); joxOut.writeObject(MarkTest, b); joxOut.close(); ByteArrayOutputStream baos = new ByteArrayOutputStream(); Reader stylesheet = null; // Get the XSLT processor XSLTProcessor processor = XSLTProcessorFactory.getProcessor(); // Create the input source Reader responseReader = new StringReader(f:/ProgramFiles/jox/source/com/wutka/jox/test/bean.xml); XSLTInputSource responseSource = new XSLTInputSource(responseReader); // Get the stylesheet String stylesheetPath = ; try { stylesheet = new FileReader(c:/stylesheet.css); } catch (FileNotFoundException fnfe) {} if (stylesheet == null) { stylesheet = new FileReader(c:/stylesheet.css); } XSLTInputSource stylesheetSource = new XSLTInputSource(stylesheet); // Get a target to contain the output Writer formWriter = new StringWriter(); XSLTResultTarget target = new XSLTResultTarget(formWriter); // Transform the XML response to fo format processor.process(responseSource, stylesheetSource, target); // Redirect the fo file from a Writer to a Reader Reader formReader = new StringReader(formWriter.toString()); // Transform from fop to pdf XMLReader xmlReader = new SAXParser(); Driver driver = new Driver(); driver.setRenderer(new org.apache.fop.render.pdf.PDFRenderer ()); driver.addElementMapping(org.apache.fop.fo.StandardElementMapping); driver.addElementMapping(org.apache.fop.svg.SVGElementMapping); driver.addPropertyList(org.apache.fop.fo.StandardPropertyListMapping); driver.addPropertyList(org.apache.fop.svg.SVGPropertyListMapping); driver.setOutputStream(new BufferedOutputStream(baos)); driver.buildFOTree(xmlReader, new InputSource(formReader)); driver.format(); driver.render(); // Clean up baos.close(); stylesheet.close(); } catch (Exception exc
Re: Haw to insert different text into headers.
Try something like this: fo:layout-master-set fo:simple-page-master master-name=first-page page-height=29.7cm page-width=21cm margin-top=1.0cm margin-left=1.76cm margin-right=4.0cm fo:region-before region-name=header-first extent=6.0cm/ fo:region-body margin-top=6.1cm margin-bottom=3.1cm/ /fo:simple-page-master fo:simple-page-master master-name=all-other-page page-height=29.7cm page-width=21cm margin-top=1.0cm margin-left=1.76cm margin-right=3.0cm fo:region-before region-name=header-rest extent=3.5cm/ fo:region-body margin-top=3.6cm margin-bottom=3.1cm/ /fo:simple-page-master fo:page-sequence-master master-name=content fo:single-page-master-reference master-name= first-page page-position=first initial-page-number=1/ fo:repeatable-page-master-alternatives fo:conditional-page-master-reference master-name =all-other-page/ /fo:repeatable-page-master-alternatives /fo:page-sequence-master /fo:layout-master-set fo:page-sequence master-name=content xsl:call-template name=firstheader/ xsl:call-template name=restheader/ fo:flow flow-name=xsl-region-body fo:block/fo:block /fo:flow /fo:page-sequence xsl:template name=firstheader fo:static-content flow-name=header-first fo:block/fo:block /fo:static-content /xsl:template xsl:template name=restheader fo:static-content flow-name=header-rest fo:block/fo:block /fo:static-content /xsl:template Hope it gives you a hint :) Claus Nielsen Denmark Dariusz Grabowski To: [EMAIL PROTECTED] dariusz.grabows cc: [EMAIL PROTECTED] Subject: Haw to insert different text into headers. 03-01-2001 17:08 Please respond to fop-dev I try create simple document with four pages. The document contains only text. In the header I must put some texts. First page must contains different text than rest of a pages. I know haw to create different layouts using fo:page-sequence-master. But I don't know haw to insert different text in header on first page and another text in header in next pages? Help me. DarekG - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Problem running version .20.1
Hello Betty. You need to put all the .jar files from the FOP to your classpath Betty Harvey betty@eccnet. To: [EMAIL PROTECTED] com cc: Subject: Problem running version .20.1 02-01-2002 19:06 Please respond to fop-dev I have just installed version .20.1 of FOP and am receiving the following error when I run it using file parameters. Exception in thread main java.lang.NoClassDefFoundError: org/apache/fop/apps/Fop Anyone have any ideas? Thanks. Betty /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/ Betty Harvey, XML Consultant,| Phone: 410-787-9200 FAX: 9830 Electronic Commerce Connection, Inc. | [EMAIL PROTECTED]| Washington,DC SGML/XML Users Grp URL: http://www.eccnet.com | http://www.eccnet.com/xmlug/ /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\\/\/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: Flow of tables please help PLEEEAAASSEE
How ? Claus Smith, Paul paul_smith@uk To: '[EMAIL PROTECTED]' [EMAIL PROTECTED] .appl.net cc: Subject: RE: Flow of tables please help PLEEEAAASSEE 11-12-2001 12:17 Please respond to fop-dev Put the tables in a table. --- Paul Smith I have 3 tables amongst other items on my page. The rest of the stuff on my page is 100%, its just these three tables. table table table At the moment theyr'e being stacked under each other. what i need is for them to be placed next to each other from left to right. So what i want is this table table table *** DISCLAIMER: The information contained in this email is confidential and is intended solely for the use of the named addressee. Access, copying or re-use of the information in it by any other person is not authorised. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: how to set userconfig.xml using org.apache.fop.apps.Driver
try { File userConfigFile = new File(userconfig.xml); Options options = new Options(userConfigFile); } catch (FOPException e) {} Driver driver = new Driver(); This should do it. Claus Gabrovsky, Ivaylo To: [EMAIL PROTECTED] IGabrovsky@sk cc: andia.com Subject: how to set userconfig.xml using org.apache.fop.apps.Driver 11-12-2001 23:48 Please respond to fop-dev Hi all, I found some font metric *.xml files and edited my conf\userconfig.xml to use them. What is equivalent of fop -c conf\userconfig.xml ... rendering with org.apache.fop.apps.Driver? Thank you. Ivaylo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: [PATCH] update FOP (maintenance branch) to REC syntax
Christian, When is page-position last correct implemented ? Claus Christian Geisert Christian.Geisert@is To: [EMAIL PROTECTED] u-gmbh.de cc: Subject: [PATCH] update FOP (maintenance branch) to REC syntax 05-12-2001 16:38 Please respond to fop-dev Hi, I finally managed to update FOP to REC syntax.. According to the documented changes at: http://www.w3.org/TR/2001/REC-xsl-20011015/sliceF.html#changes http://www.w3.org/TR/2001/PR-xsl-20010828/sliceF.html#changes the biggest thing was the renaming of the master-name property to master-reference on fo:page-sequence, fo:single-page-master-reference, fo:repeatable-page-master-reference and fo:conditional-page-master-reference. I've also updated all files in docs/examples, run the tests - and it looks good :-) Next I will have a look a the test directory Christian Index: docs/examples/advanced/cid-fonts.fo === RCS file: /home/cvspublic/xml-fop/docs/examples/advanced/cid-fonts.fo,v retrieving revision 1.2 diff -u -u -r1.2 cid-fonts.fo --- docs/examples/advanced/cid-fonts.fo 2001/05/18 09:55:46 1.2 +++ docs/examples/advanced/cid-fonts.fo 2001/12/05 14:11:04 @@ -70,7 +70,7 @@ /fox:outline - fo:page-sequence master-name=A4 + fo:page-sequence master-reference=A4 fo:flow flow-name=xsl-region-body fo:wrapper font-family=Times font-size=12pt text-align=justify Index: docs/examples/advanced/giro.fo === RCS file: /home/cvspublic/xml-fop/docs/examples/advanced/giro.fo,v retrieving revision 1.1 diff -u -u -r1.1 giro.fo --- docs/examples/advanced/giro.fo 2001/03/04 18:00:38 1.1 +++ docs/examples/advanced/giro.fo 2001/12/05 14:11:18 @@ -10,13 +10,13 @@ /fo:simple-page-master fo:page-sequence-master master-name=A4 fo:repeatable-page-master-alternatives -fo:conditional-page-master-reference master-name=first page-position=first/ -fo:conditional-page-master-reference master-name=rest page-position=rest/ -fo:conditional-page-master-reference master-name=rest/ +fo:conditional-page-master-reference master-reference=first page-position=first/ +fo:conditional-page-master-reference master-reference=rest page-position=rest/ +fo:conditional-page-master-reference master-reference =rest/ /fo:repeatable-page-master-alternatives /fo:page-sequence-master /fo:layout-master-set - fo:page-sequence master-name=A4 + fo:page-sequence master-reference=A4 fo:static-content flow-name=xsl-region-after fo:table space-before.optimum=1in div 12 margin-left=2in div 12 margin-top=1in div 10 font-family=sans-serif font-size=7pt color =green fo:table-column column-width=8in div 10 - 2in div 12/ @@ -1241,4 +1241,4 @@ fo:blockSVG logo and bar code/fo:block /fo:flow /fo:page-sequence -/fo:root \ No newline at end of file +/fo:root Index: docs/examples/fo/border.fo === RCS file: /home/cvspublic/xml-fop/docs/examples/fo/border.fo,v retrieving revision 1.8 diff -u -u -r1.8 border.fo --- docs/examples/fo/border.fo 2001/10/14 21:03:14 1.8 +++ docs/examples/fo/border.fo 2001/12/05 14:11:20 @@ -13,16 +13,16 @@ fo:page-sequence-master master-name=psmA fo:repeatable-page-master-alternatives - fo:conditional-page-master-reference master-name =first + fo:conditional-page-master-reference master-reference =first page-position=first / - fo:conditional-page-master-reference master-name =rest + fo:conditional-page-master-reference master-reference =rest page-position=rest / !-- recommended fallback procedure -- -