Setting up headers and footers for preface topics
Here should go questions about transforming XML with XSLT and FOP.
-
- Posts: 37
- Joined: Wed May 13, 2015 11:02 am
Setting up headers and footers for preface topics
I struggle with headers and footers for my preface topics. I use the latest OT 2.5.
Consider this bookmap structure:
I set force_page_count to "auto" in order to have a straight page flow without any blank pages and continuous numbering. When I publish to PDF, I get this result: https://www.dropbox.com/s/7cn6kz4qbyy4w ... p.pdf?dl=0.
In order to know what header information actually is written in each preface topic, I modified en.xml with ODD, EVEN and FIRST infos:
My expectation was that the first preface starts EVEN, the second ODD and the third again EVEN. Instead, the second starts FIRST. The first and third don't even output any header information at all and therefore no styling can be applied.
Is this a bug in the OT? Of course, if I set force_page_count to "even" then every preface topic is FIRST, so this is correct. But with "auto" there seems to be some hick-up. If I replicate this in OT 1.8.5, then I get a different result: first preface is ODD, the second FIRST and the third again ODD. Here at least the header output works somehow, but still not consistently ODD/EVEN as I would expect it. See example: https://www.dropbox.com/s/1tnjtd3hv9z9n ... 5.pdf?dl=0
Thanks for clarification.
Chris.
Consider this bookmap structure:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE bookmap PUBLIC "-//OASIS//DTD DITA BookMap//EN" "bookmap.dtd">
<bookmap>
<booktitle>
<mainbooktitle>Preface Test Map</mainbooktitle>
</booktitle>
<frontmatter>
<preface href="preface1.dita"/>
<preface href="preface2.dita"/>
<preface href="preface3.dita"/>
<booklists>
<toc/>
</booklists>
</frontmatter>
</bookmap>
In order to know what header information actually is written in each preface topic, I modified en.xml with ODD, EVEN and FIRST infos:
Code: Select all
<!-- The header that appears on Preface odd-numbered pages. -->
<variable id="Preface odd header"><param ref-name="prodname"/> |ODD| <param ref-name="pagenum"/></variable>
<!-- The header that appears on Preface even-numbered pages. -->
<variable id="Preface even header"><param ref-name="pagenum"/> |EVEN| <param ref-name="prodname"/></variable>
<!-- The header that appears on Preface first page. -->
<variable id="Preface first header"><param ref-name="pagenum"/> |FIRST| <param ref-name="prodname"/></variable>
Is this a bug in the OT? Of course, if I set force_page_count to "even" then every preface topic is FIRST, so this is correct. But with "auto" there seems to be some hick-up. If I replicate this in OT 1.8.5, then I get a different result: first preface is ODD, the second FIRST and the third again ODD. Here at least the header output works somehow, but still not consistently ODD/EVEN as I would expect it. See example: https://www.dropbox.com/s/1tnjtd3hv9z9n ... 5.pdf?dl=0
Thanks for clarification.
Chris.
-
- Posts: 37
- Joined: Wed May 13, 2015 11:02 am
Re: Setting up headers and footers for preface topics
After some fiddling with the code, I realized i can set in "generate-page-sequence-master" first and last to false:
Now my preface-pages pick up the headers and footers correctly.
Code: Select all
<xsl:param name="first" select="false()"/>
<xsl:param name="last" select="false()"/>
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service