xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "robyp7 ." <rob...@gmail.com>
Subject how can override the start fo:page-number in xsl:fo with my number
Date Mon, 07 Sep 2015 12:28:53 GMT

i use an old fop lib version 0.20.5
I have an xsl:fo with

<fo:block text-align="end">

       *Page number :*<fo:page-number />
this is in the footer

I need to create a PDF with a initial number > 1 and for ex. 10 or 11 or
some other else..

So the first page begin with 10, the secondo eith 11 and so..

I need to pass this number as parameter from jsp web page to my bean/java
classes that call the fop rendering

I implement a CustomRender (it extend the class org
and i override tese two method:

*public* *void* render(Page page, OutputStream outputStream){

*throws* IOException, FOPException {


System.out.println("##@@## Rendering page " + page.getNumber());


renderer.render(page, outputStream);


*public* *void* renderPage(Page page){

System.out.println("@@##@@ Rendering page " + page.getNumber());




but page.setNumber(pageCount); doesn't seem to work!

How can I do this work?
Thanks in advice!


View raw message