You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Franz de Copenhague <fr...@outlook.com> on 2015/09/30 21:34:36 UTC

fop-users@xmlgraphics.apache.org

This is my first question to the list.

I did try to google the way to have page numbers with roman numbers but I couldn't figure it out.

Would you modify the example below to illustrate me how to achieve roman page numbers?

<?xml version="1.0" encoding="utf-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
    <fo:layout-master-set>
       
 <fo:simple-page-master master-name="simple" page-height="29.7cm" 
page-width="21cm" margin-top="1cm" margin-bottom="2cm" 
margin-left="2.5cm" margin-right="2.5cm">
            <fo:region-body margin-top="3cm"/>
            <fo:region-before extent="3cm"/>
            <fo:region-after extent="1.5cm"/>
        </fo:simple-page-master>
    </fo:layout-master-set>
    <fo:page-sequence master-reference="simple" initial-page-number="20">
        <fo:static-content flow-name="xsl-region-before">
            <fo:block text-align="end">page <fo:page-number/></fo:block>
        </fo:static-content>
        <fo:flow flow-name="xsl-region-body">
            <fo:block> I would like to see page XX on top </fo:block>
        </fo:flow>
    </fo:page-sequence>
</fo:root>



Thanks,
Franz 		 	   		  

RE: fop-users@xmlgraphics.apache.org

Posted by Franz de Copenhague <fr...@outlook.com>.
Peter,

Thank you! Like you say, It solves my problem  http://www.dpawson.co.uk/xsl/sect3/N8703.html#d12988e73

Actually, for upper-roman I did have to set the attribute format to "I"

Thanks,
Franz

From: pc.subscriptions@gmail.com
Subject: Re: fop-users@xmlgraphics.apache.org
Date: Wed, 30 Sep 2015 22:10:22 +0200
To: fop-users@xmlgraphics.apache.org

See http://www.dpawson.co.uk/xsl/sect3/N8703.html
<?xml version="1.0" encoding="utf-8"?><fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">    <fo:layout-master-set>        <fo:simple-page-master master-name="simple" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">            <fo:region-body margin-top="3cm"/>            <fo:region-before extent="3cm"/>            <fo:region-after extent="1.5cm"/>        </fo:simple-page-master>    </fo:layout-master-set>    <fo:page-sequence master-reference="simple" initial-page-number="20" format="i" >        <fo:static-content flow-name="xsl-region-before">            <fo:block text-align="end">page <fo:page-number/></fo:block>        </fo:static-content>        <fo:flow flow-name="xsl-region-body">            <fo:block> I would like to see page XX on top </fo:block>        </fo:flow>    </fo:page-sequence></fo:root>



Peter
On 30 Sep 2015, at 21:53, Franz de Copenhague <fr...@outlook.com> wrote:It didn't help. It throws this exception: SEVERE: Invalid property value encountered in initial-page-number="XX": org.apache.fop.fo.expr.PropertyException

I wish could be an attribute similar to:

<fo:page-sequence master-reference="simple" initial-page-number="20" page-number-style= "upper-roman">

Franz
To: fop-users@xmlgraphics.apache.org
From: rsargent@xmission.com
Date: Wed, 30 Sep 2015 13:35:26 -0600
Subject: Re: fop-users@xmlgraphics.apache.org

Did you try
    initial-page-number="XX"
?

On 09/30/2015 01:34 PM, Franz de Copenhague wrote:
This is my first question to the list.

I did try to google the way to have page numbers with roman numbers but I couldn't figure it out.

Would you modify the example below to illustrate me how to achieve roman page numbers?

<?xml version="1.0" encoding="utf-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
    <fo:layout-master-set>
        <fo:simple-page-master master-name="simple" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">
            <fo:region-body margin-top="3cm"/>
            <fo:region-before extent="3cm"/>
            <fo:region-after extent="1.5cm"/>
        </fo:simple-page-master>
    </fo:layout-master-set>
    <fo:page-sequence master-reference="simple" initial-page-number="20">
        <fo:static-content flow-name="xsl-region-before">
            <fo:block text-align="end">page <fo:page-number/></fo:block>
        </fo:static-content>
        <fo:flow flow-name="xsl-region-body">
            <fo:block> I would like to see page XX on top </fo:block>
        </fo:flow>
    </fo:page-sequence>
</fo:root>



Thanks,
Franz 
 		 	   		  

Re: fop-users@xmlgraphics.apache.org

Posted by Peter Coppens <pc...@gmail.com>.
See http://www.dpawson.co.uk/xsl/sect3/N8703.html <http://www.dpawson.co.uk/xsl/sect3/N8703.html>

<?xml version="1.0" encoding="utf-8"?>
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
    <fo:layout-master-set>
        <fo:simple-page-master master-name="simple" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">
            <fo:region-body margin-top="3cm"/>
            <fo:region-before extent="3cm"/>
            <fo:region-after extent="1.5cm"/>
        </fo:simple-page-master>
    </fo:layout-master-set>
    <fo:page-sequence master-reference="simple" initial-page-number="20" format="i" >
        <fo:static-content flow-name="xsl-region-before">
            <fo:block text-align="end">page <fo:page-number/></fo:block>
        </fo:static-content>
        <fo:flow flow-name="xsl-region-body">
            <fo:block> I would like to see page XX on top </fo:block>
        </fo:flow>
    </fo:page-sequence>
</fo:root>




Peter

> On 30 Sep 2015, at 21:53, Franz de Copenhague <fr...@outlook.com> wrote:
> 
> It didn't help. It throws this exception: SEVERE: Invalid property value encountered in initial-page-number="XX": org.apache.fop.fo.expr.PropertyException
> 
> I wish could be an attribute similar to:
> 
> <fo:page-sequence master-reference="simple" initial-page-number="20" page-number-style= "upper-roman">
> 
> Franz
> To: fop-users@xmlgraphics.apache.org <ma...@xmlgraphics.apache.org>
> From: rsargent@xmission.com <ma...@xmission.com>
> Date: Wed, 30 Sep 2015 13:35:26 -0600
> Subject: Re: fop-users@xmlgraphics.apache.org <ma...@xmlgraphics.apache.org>
> 
> Did you try
>     initial-page-number="XX"
> ?
> 
> On 09/30/2015 01:34 PM, Franz de Copenhague wrote:
> This is my first question to the list.
> 
> I did try to google the way to have page numbers with roman numbers but I couldn't figure it out.
> 
> Would you modify the example below to illustrate me how to achieve roman page numbers?
> 
> <?xml version="1.0" encoding="utf-8"?>
> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format <http://www.w3.org/1999/XSL/Format>">
>     <fo:layout-master-set>
>         <fo:simple-page-master master-name="simple" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">
>             <fo:region-body margin-top="3cm"/>
>             <fo:region-before extent="3cm"/>
>             <fo:region-after extent="1.5cm"/>
>         </fo:simple-page-master>
>     </fo:layout-master-set>
>     <fo:page-sequence master-reference="simple" initial-page-number="20">
>         <fo:static-content flow-name="xsl-region-before">
>             <fo:block text-align="end">page <fo:page-number/></fo:block>
>         </fo:static-content>
>         <fo:flow flow-name="xsl-region-body">
>             <fo:block> I would like to see page XX on top </fo:block>
>         </fo:flow>
>     </fo:page-sequence>
> </fo:root>
> 
> 
> 
> Thanks,
> Franz 


RE: fop-users@xmlgraphics.apache.org

Posted by Franz de Copenhague <fr...@outlook.com>.
It didn't help. It throws this exception: SEVERE: Invalid property value encountered in initial-page-number="XX": org.apache.fop.fo.expr.PropertyException

I wish could be an attribute similar to:

<fo:page-sequence master-reference="simple"
        initial-page-number="20" page-number-style= "upper-roman">

Franz
To: fop-users@xmlgraphics.apache.org
From: rsargent@xmission.com
Date: Wed, 30 Sep 2015 13:35:26 -0600
Subject: Re: fop-users@xmlgraphics.apache.org


  
    
  
  
    Did you try

          initial-page-number="XX"

      ?

    

    On 09/30/2015 01:34 PM, Franz de
      Copenhague wrote:

    
    
      
      This is my first question to the list.

        

        I did try to google the way to have page numbers with roman
        numbers but I couldn't figure it out.

        

        Would you modify the example below to illustrate me how to
        achieve roman page numbers?

        

        <?xml version="1.0" encoding="utf-8"?>

        <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">

            <fo:layout-master-set>

                <fo:simple-page-master master-name="simple"
        page-height="29.7cm" page-width="21cm" margin-top="1cm"
        margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">

                    <fo:region-body margin-top="3cm"/>

                    <fo:region-before extent="3cm"/>

                    <fo:region-after extent="1.5cm"/>

                </fo:simple-page-master>

            </fo:layout-master-set>

            <fo:page-sequence master-reference="simple"
        initial-page-number="20">

                <fo:static-content flow-name="xsl-region-before">

                    <fo:block text-align="end">page
        <fo:page-number/></fo:block>

                </fo:static-content>

                <fo:flow flow-name="xsl-region-body">

                    <fo:block> I would like to see page XX on top
        </fo:block>

                </fo:flow>

            </fo:page-sequence>

        </fo:root>

        

        

        

        Thanks,

        Franz 
    
    
 		 	   		  

Re: fop-users@xmlgraphics.apache.org

Posted by Rob Sargent <rs...@xmission.com>.
Did you try
     initial-page-number="XX"
?

On 09/30/2015 01:34 PM, Franz de Copenhague wrote:
> This is my first question to the list.
>
> I did try to google the way to have page numbers with roman numbers 
> but I couldn't figure it out.
>
> Would you modify the example below to illustrate me how to achieve 
> roman page numbers?
>
> <?xml version="1.0" encoding="utf-8"?>
> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
>     <fo:layout-master-set>
>         <fo:simple-page-master master-name="simple" 
> page-height="29.7cm" page-width="21cm" margin-top="1cm" 
> margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm">
>             <fo:region-body margin-top="3cm"/>
>             <fo:region-before extent="3cm"/>
>             <fo:region-after extent="1.5cm"/>
>         </fo:simple-page-master>
>     </fo:layout-master-set>
>     <fo:page-sequence master-reference="simple" initial-page-number="20">
>         <fo:static-content flow-name="xsl-region-before">
>             <fo:block text-align="end">page <fo:page-number/></fo:block>
>         </fo:static-content>
>         <fo:flow flow-name="xsl-region-body">
>             <fo:block> I would like to see page XX on top </fo:block>
>         </fo:flow>
>     </fo:page-sequence>
> </fo:root>
>
>
>
> Thanks,
> Franz