[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: [FO] page-sequence/@initial-page-number creates bl

Subject: Re: [FO] page-sequence/@initial-page-number creates blank page
From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 19 Jun 2009 09:52:53 -0400
Re:  [FO] page-sequence/@initial-page-number creates bl
At 2009-06-19 13:10 +0000, Florent Georges wrote:
I've just found a weird behaviour with the following document:

<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="m" margin="7.5mm"
page-height="210mm" page-width="297mm">
<fo:region-body/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="m">
<fo:flow flow-name="xsl-region-body">
<fo:block>block</fo:block>
</fo:flow>
</fo:page-sequence>
<fo:page-sequence master-reference="m"
initial-page-number="1">
<fo:flow flow-name="xsl-region-body">
<fo:block>block</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>


 The result is a document in 3 pages, with the word "block" on
the first and the last one (as expected) but with an extra blank
page between them (this one is not expected.)

Actually, it is expected.


 If I remove @initial-page-number, the result is as expected
(except that my real problem does rely on this attribute to have
correct number pages, of course.)

 Is it a problem of my processor or is it the expected behaviour
(or did I do something wrong?)

You asked for a second page sequence starting at page number 1. Odd page numbers are typically on the opposite side of even numbered pages, so the processor adds a blank page to the first page sequence.


If what you want is two consecutive pages numbered 1, then stop the forcing of the blank page in the first page sequence, as below.

I hope this helps.

. . . . . . . . . Ken

   <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
      <fo:layout-master-set>
         <fo:simple-page-master
               master-name="m" margin="7.5mm"
               page-height="210mm" page-width="297mm">
            <fo:region-body/>
         </fo:simple-page-master>
      </fo:layout-master-set>
      <fo:page-sequence master-reference="m" force-page-count="no-force">
         <fo:flow flow-name="xsl-region-body">
            <fo:block>block</fo:block>
         </fo:flow>
      </fo:page-sequence>
      <fo:page-sequence master-reference="m"
                        initial-page-number="1">
         <fo:flow flow-name="xsl-region-body">
            <fo:block>block</fo:block>
         </fo:flow>
      </fo:page-sequence>
   </fo:root>



--
Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/s/
Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
Video lesson:    http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
Video overview:  http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
G. Ken Holman                 mailto:gkholman@xxxxxxxxxxxxxxxxxxxx
Male Cancer Awareness Nov'07  http://www.CraneSoftwrights.com/s/bc
Legal business disclaimers:  http://www.CraneSoftwrights.com/legal

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.