[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] How to remove blank pages between chapters using FOP
If you are customizing initial.page.number, then in the single-sided output
section, in the xsl:when for the first chapter, use 'auto-odd'. Leave
'auto' for the xsl:otherwise, which will be used for the other chapters.
<xsl:when test="($element = 'chapter' or $element = 'appendix') and
not(preceding::chapter
or preceding::appendix
or preceding::article
or preceding::dedication
or parent::part
or parent::reference)">auto-odd</xsl:when>
<xsl:otherwise>auto</xsl:otherwise>
Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net
----- Original Message -----
From: "Ken Van Mersbergen" <kenvm97@yahoo.com>
To: "Bob Stayton" <bobs@sagehill.net>
Cc: <docbook-apps@lists.oasis-open.org>
Sent: Monday, May 01, 2006 12:08 PM
Subject: Re: [docbook-apps] How to remove blank pages between chapters
using FOP
> Hi Bob,
>
> Thank you for reminding me of the double.sided parameter. I set that back
> to
> zero, and that eliminated all of the extra blank pages. When I tried to
> customize the 'initial.page.number' template, the result was either the
> page
> number of chapter one was set to 14 or, nothing. This is strange. So
> let's take
> a different approach: with the double.sided parameter set to zero, how do
> I
> force the first chapter to start on an odd page?
>
> Thanks,
> Ken
>
> --- Bob Stayton <bobs@sagehill.net> wrote:
>
>> Hi Ken,
>> One way to do it is to set the stylesheet parameter double.sided to
>> zero,
>> which is the default value. That turns off the generated blank
>> even-numbered pages, but it also changes the headers and footers and
>> margins.
>>
>> To just change the starting page, you can customize the template named
>> 'initial.page.number' in fo/pagesetup.xsl. When that stylesheet returns
>> a
>> value of auto-odd, you get the blank pages. If you change that to
>> 'auto',
>> then it won't force the chapter starts onto an odd page. The template
>> handles various elements in different ways. If you just want to change
>> the
>> behavior for any chapters after the first, then you just need to change
>> the
>> first xsl:otherwise clause:
>>
>> <xsl:otherwise>auto</xsl:otherwise>
>>
>> Bob Stayton
>> Sagehill Enterprises
>> DocBook Consulting
>> bobs@sagehill.net
>>
>>
>> ----- Original Message -----
>> From: "Ken Van Mersbergen" <kenvm97@yahoo.com>
>> To: <docbook-apps@lists.oasis-open.org>
>> Sent: Thursday, April 27, 2006 11:11 AM
>> Subject: [docbook-apps] How to remove blank pages between chapters using
>> FOP
>>
>>
>> > How do I customize xsl stylesheets v1.68.1 to remove blank pages
>> > between
>> > chapters when the output is a pdf from FOP? For example Chapter 1
>> > starts
>> > on
>> > page 1 (a recto page) and ends on page 3 (a recto page). I want
>> > Chapter 2
>> > to
>> > start on page 4 (a verso page) and end on, for example, page 10 (a
>> > verso
>> > page).
>> > I don't always know if a chapter (or ToC, preface, glossary, etc.)
>> > will
>> > end on
>> > a recto page or a verso page. If it does end on a recto page, I want
>> > the
>> > next
>> > section to start on the following verso page.
>> >
>> > Thanks,
>> >
>> > Ken Van Mersbergen
>> > Tedras Global Solutions
>> >
>> > __________________________________________________
>> > Do You Yahoo!?
>> > Tired of spam? Yahoo! Mail has the best spam protection around
>> > http://mail.yahoo.com
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
>> > For additional commands, e-mail:
>> > docbook-apps-help@lists.oasis-open.org
>> >
>> >
>> >
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
>> For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org
>>
>>
>
>
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>
>
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]