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: Page numbering, FOP version
You can do the page 1/(total nb of pages) using some last block reference. I mean you can generate a block with a special id, like my-very-last-paragraph within the last page. then, you can use a page-number-citation that refers to your my-very-last-paragraph block. as for the last FOP dist, I have the very same question you ask ... where is the last REC dist ? Hope that helps Cyril At 11:46 07/01/2002 -0500, you wrote: 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]
Re: page numbering question
I've done a fair amount of the stuff related to pagination, so even though I am currently in Vancouver on vacation, and away from all of my reference stuff, off the top of my pointy head I'd say, No, I don't think you can do what you want to do. Because you would have to add or subtract to fo:page-number, and you cannot currently do things like that. However, I'd say that this is something that would make for a very nice FOP extension; sort of an enhanced page-numbering. Regards, Arved Sandstrom Quoting Savino, Matt C [EMAIL PROTECTED]: I need to separately keep track of and print out page numbers within a sub-section of the master document. I could start a new page-sequence, but the problem is that I have a master header which needs to show the running page number of the entire document. Page |-- Header --| |-- Page 5 of 25 --| || |-- Subsection | |-- Page 1 of 6 | || Page |-- Header --| |-- Page 6 of 25 --| || |-- Subsection | |-- Page 2 of 6 | || Can FOP do anything like this? I hope I'm making myself clear. It would be easy enough if I could manipulate fo:page-number to add or subtract a fixed number. But I don't see this ability. Any ideas at all would be greatly appreciated. Thanks -Matt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] --- This mail was sent through the Nova Scotia Provincial Server, with technical resources provided by Chebucto Community Net. http://nsaccess.ns.ca/mail/ http://www.chebucto.ns.ca/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
page numbering question
I need to separately keep track of and print out page numbers within a sub-section of the master document. I could start a new page-sequence, but the problem is that I have a master header which needs to show the running page number of the entire document. Page |-- Header --| |-- Page 5 of 25 --| || |-- Subsection | |-- Page 1 of 6 | || Page |-- Header --| |-- Page 6 of 25 --| || |-- Subsection | |-- Page 2 of 6 | || Can FOP do anything like this? I hope I'm making myself clear. It would be easy enough if I could manipulate fo:page-number to add or subtract a fixed number. But I don't see this ability. Any ideas at all would be greatly appreciated. Thanks -Matt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: Antwort: page numbering problem...
you could try something like: xsl:template match=report xsl:variable name=this-page-sequence select=concat('EOR',position())/ fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-before xsl:textReport /xsl:text xsl:value-of select=title /fo:static-content fo:static-content flow-name=xsl-region-after fo:blockfo:leader leader-pattern=rule leader-length =max//fo:block fo:block text-align=endxsl:textPage /xsl:textfo:page-number//fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates xsl:with-param name=this-page-sequence select=$this-page-sequence/ /xsl:apply-templates !-- -- fo:block height=0mm width=0mm xsl:attribute name=idxsl:value-of select=$this-page-sequence//xsl:attribute /fo:block !-- -- /fo:flow /fo:page-sequence /xsl:template xsl:template match=somenode xsl:param name=this-page-sequence/ !-- some other fo stuff -- fo:page-number-citation ref-id=$this-page-sequence/ /xsl:template -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: 19 October 2001 02:40 To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: Antwort: page numbering problem... thanx Joerg. It worked ... but one problem still persists. I actually wanted to display page 1 of total pages. But in this case, I can't do it coz FOP does not allow to declare a block with same id more than once in a document. So the known method of getting the total page numbers (fo:page-number-citation ref-id =endofdoc/) can't work here as it does not let me declare the block with this name in every page sequence. Moreover is there any limitation with the maximum number of page sequences we can have in one document.? Is there any wayout Please help thanks wali Hi wali, I creat a PDF document which have reports for different customers. One document can contain many reports. Now I want to mark the pages for reports individually. i.e. ... Every new report starts at new page. and every report can consist of different number of pages. Create a page sequence for each report. If you are creating the FO via XSLT, and if you have the reports in individual XML elements (here called report), you can use something like xsl:template match=report fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-before xsl:textReport /xsl:text xsl:value-of select=title /fo:static-content fo:static-content flow-name=xsl-region-after fo:blockfo:leader leader-pattern=rule leader-length =max//fo:block fo:block text-align=endxsl:textPage /xsl:textfo:page-number//fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates/ /fo:flow /fo:page-sequence /xsl:template Tailor this to your needs. Of course you'll have to define a page master report (you may have different page masters for the title page, the TOC, appendices etc.) HTH Joerg Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - 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: page numbering problem...
Thanx Joerg and Colin It is working fine Thanx again for your help. This is how i have done it xsl:template match=report xsl:param name=ReportNo select=position()/ fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-after fo:block text-align=end xsl:textPage /xsl:text fo:page-number/ xsl:text of /xsl:text fo:page-number-citation ref-id={$ReportNo}/ /fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates/ fo:block id={$ReportNo}/ /fo:flow /fo:page-sequence /xsl:template wali Hi wali, but one problem still persists can't do it coz FOP does not allow to declare a block with same id more than once in a document. Use an individually generated id for each end-block. There are various methods in XSL (so this is more a Q for the XSL-List). Try generate-id() for most robustness. The following uses the generated id of the report element which generates the flow. untested) xsl:template match=report fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-after fo:block text-align=end xsl:textPage /xsl:text fo:page-number/ xsl:text of /xsl:text fo:page-number-citation ref-id=endofflow-{generate-id()}/ /fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates/ fo:block id=endofflow-{generate-id()}/ /fo:flow /fo:page-sequence /xsl:template If you want to refer to the last page number from somewhere else, you'll have to supply a XPath to the report element which created the flow, for example generate-id(ancestor::report) or generate-id(//report[2]) or something, depending of the context. HTH Joerg Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Antwort: page numbering problem...
thanx Joerg. It worked ... but one problem still persists. I actually wanted to display page 1 of total pages. But in this case, I can't do it coz FOP does not allow to declare a block with same id more than once in a document. So the known method of getting the total page numbers (fo:page-number-citation ref-id =endofdoc/) can't work here as it does not let me declare the block with this name in every page sequence. Moreover is there any limitation with the maximum number of page sequences we can have in one document.? Is there any wayout Please help thanks wali Hi wali, I creat a PDF document which have reports for different customers. One document can contain many reports. Now I want to mark the pages for reports individually. i.e. ... Every new report starts at new page. and every report can consist of different number of pages. Create a page sequence for each report. If you are creating the FO via XSLT, and if you have the reports in individual XML elements (here called report), you can use something like xsl:template match=report fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-before xsl:textReport /xsl:text xsl:value-of select=title /fo:static-content fo:static-content flow-name=xsl-region-after fo:blockfo:leader leader-pattern=rule leader-length =max//fo:block fo:block text-align=endxsl:textPage /xsl:textfo:page-number//fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates/ /fo:flow /fo:page-sequence /xsl:template Tailor this to your needs. Of course you'll have to define a page master report (you may have different page masters for the title page, the TOC, appendices etc.) HTH Joerg Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Antwort: page numbering problem...
Hi wali, I creat a PDF document which have reports for different customers. One document can contain many reports. Now I want to mark the pages for reports individually. i.e. ... Every new report starts at new page. and every report can consist of different number of pages. Create a page sequence for each report. If you are creating the FO via XSLT, and if you have the reports in individual XML elements (here called report), you can use something like xsl:template match=report fo:page-sequence master-name=report initial-page-number=1 fo:static-content flow-name=xsl-region-before xsl:textReport /xsl:text xsl:value-of select=title /fo:static-content fo:static-content flow-name=xsl-region-after fo:blockfo:leader leader-pattern=rule leader-length =max//fo:block fo:block text-align=endxsl:textPage /xsl:textfo:page-number//fo:block /fo:static-content fo:flow flow-name=xsl-region-body xsl:apply-templates/ /fo:flow /fo:page-sequence /xsl:template Tailor this to your needs. Of course you'll have to define a page master report (you may have different page masters for the title page, the TOC, appendices etc.) HTH Joerg Pietschmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: page numbering
On Tue, 10 Jul 2001 22:05:41 eric.deandrea wrote: I am using FOP 0.14. Any help would be greatly appreciated! I don't think that 0.14 had page numbering. I would suggest trying the latest FOP. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]