PDF output: <indexterm> in sections causes empty row
Post here questions and problems related to editing and publishing DITA content.
PDF output: <indexterm> in sections causes empty row
Post by Anonymous1 »
Hello,
until now we used indexterm elements in the prolog only. Now we want to allow our authors to also use it in sections. According to the DITA specs this is fine.
We've only got one issue in our PDF output. When we insert an indexterm element in a section element, an empty row is created. Everything else works.
A visualization
Section without indexterm:
We are using Oxygen 19, build 2017042020 with a custom framework.
Thanks,
Benjamin
until now we used indexterm elements in the prolog only. Now we want to allow our authors to also use it in sections. According to the DITA specs this is fine.
We've only got one issue in our PDF output. When we insert an indexterm element in a section element, an empty row is created. Everything else works.
A visualization
Section without indexterm:
Section with indexterm:Section Title
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.
Do you have an idea why this could be?Section Title
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.
We are using Oxygen 19, build 2017042020 with a custom framework.
Thanks,
Benjamin
-
- Posts: 407
- Joined: Mon Dec 05, 2011 6:08 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Benjamin,
You are using the DITA Map PDF transformation scenario, right?
I have tested in a default installation of oXygen XML v19.1 with the built-in DITA-OT 2.x on our sample project flowers.ditamap and I could not reproduce this issue. I have added in a topic two sections one with indexterm and another one without indexterm and both sections are rendered correctly in the PDF output, without an empty row (by running the built-it DITA Map PDF transformation scenario).
The problem you've indicated might be triggered by the customizations you are using.
To further investigate this issue, could you please try in a clean installation of oXygen XML with the buil-it DITA-OT and the default transformation scenario to check if you reproduce the problem.
Regards,
Ionela
You are using the DITA Map PDF transformation scenario, right?
I have tested in a default installation of oXygen XML v19.1 with the built-in DITA-OT 2.x on our sample project flowers.ditamap and I could not reproduce this issue. I have added in a topic two sections one with indexterm and another one without indexterm and both sections are rendered correctly in the PDF output, without an empty row (by running the built-it DITA Map PDF transformation scenario).
The problem you've indicated might be triggered by the customizations you are using.
To further investigate this issue, could you please try in a clean installation of oXygen XML with the buil-it DITA-OT and the default transformation scenario to check if you reproduce the problem.
Regards,
Ionela
Ionela Istodor
oXygen XML Editor and Author Support
oXygen XML Editor and Author Support
-
- Posts: 152
- Joined: Fri Apr 24, 2015 12:28 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Ionela,
Benjamin asked me to check.
Unfortunately, we cannot reproduce a clean installation of Oxygen XML, at least I wouldn't know how, but I've managed to set the original framework using the built-in DITA OT.
We don't use VMs on which we could use a clean installation for these purposes.
I've used Oxygen XML 20 and compared our customized framework with the default framework output. They show exactly the same result.
If I'm not wrong, I think the most interesting part is to be found in the topic.fo files. These are the results from our framework:
Index-key placement after <title> element:
Index-key placement after section <title> element:
Default framework, index-key after title:
Default framework, index-key after section title:
In either case, the index-key after the section title is not part of the fo:block element of the title, whereas the index-key after a typical title element is embedded in the fo:block element of the title.
Could this be the issue?
Thanks,
Christina
Benjamin asked me to check.
Unfortunately, we cannot reproduce a clean installation of Oxygen XML, at least I wouldn't know how, but I've managed to set the original framework using the built-in DITA OT.
We don't use VMs on which we could use a clean installation for these purposes.
I've used Oxygen XML 20 and compared our customized framework with the default framework output. They show exactly the same result.
If I'm not wrong, I think the most interesting part is to be found in the topic.fo files. These are the results from our framework:
Index-key placement after <title> element:
Code: Select all
<fo:block font-family="Noto Sans, Arial Unicode MS" axf:line-break="strict"
border-after-style="solid" border-after-width="0pt"
border-after-color="black" space-before="17pt" space-after="8pt"
font-size="16pt" font-weight="bold" padding-top="0pt"
keep-with-next.within-column="always">
<fo:block border-left-width="0pt" border-right-width="0pt">
<fo:marker marker-class-name="current-h2">Summer Flowers</fo:marker>
<fo:inline id="unique_18"/>
<fo:inline id="_OPENTOPIC_TOC_PROCESSING_d105e852"/>
<fo:inline index-key="flowers:summer2:"/>
Summer Flowers
</fo:block>
</fo:block>
Code: Select all
<fo:block font-size="9pt" line-height="1.3em" space-before="0.6em">
<fo:block font-family="Noto Sans, Arial Unicode MS"
axf:line-break="strict" font-weight="bold" space-before="11pt"
keep-with-next.within-column="always" font-size="11pt"
start-indent="0pt + from-parent(start-indent)" space-after="8pt">test section</fo:block>
<fo:inline index-key="flowers:summer:"/>
<fo:block space-before="7pt" space-after="7pt"
color="rgb-icc(0, 0, 0, #CMYK, 0, 0, 0, 1)" text-indent="0em"
line-height="1.3em">some text for the test section
</fo:block>
</fo:block>
Code: Select all
<fo:block border-after-color="black" border-after-style="solid"
border-after-width="1pt" font-size="14pt" font-weight="bold"
keep-with-next.within-column="always" padding-top="12pt"
space-after="5pt" space-before="12pt"
line-height-shift-adjustment="disregard-shifts"
font-family="Helvetica, Arial Unicode MS, Tahoma, Batang, SimSun">
<fo:block border-end-width="0pt" border-start-width="0pt">
<fo:marker marker-class-name="current-h2">Summer Flowers</fo:marker>
<fo:wrapper id="unique_18"/>
<fo:wrapper id="_OPENTOPIC_TOC_PROCESSING_d98e852"/>
<fo:inline index-key="flowers:"/>
<fo:inline index-key="flowers:summer2:"/>
Summer Flowers
</fo:block>
</fo:block>
Code: Select all
<fo:block space-before="0.6em">
<fo:block font-weight="bold"
keep-with-next.within-column="always" space-before="15pt"
line-height-shift-adjustment="disregard-shifts"
font-family="Helvetica, Arial Unicode MS, Tahoma, Batang, SimSun">test section</fo:block>
<fo:inline index-key="flowers:"/>
<fo:inline index-key="flowers:summer:"/>
<fo:block space-after="0.6em" space-before="0.6em"
text-indent="0em">some text for the test section</fo:block>
</fo:block>
Could this be the issue?
Thanks,
Christina
oXygen XML Editor 27.1 build 2025041508
DITA OT 3.7.4
DITA OT 3.7.4
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Christina,
It would have helped if you had posted some sample DITA content to show exactly where you insert the indexterm.
I can reproduce the problem on my side with some DITA content which looks like this:
It's a bug in the Apache FOP processor:
https://github.com/dita-ot/dita-ot/issues/2455
so probably using the AntennaHouse commercial PDF processor should remove it.
Regards,
Radu
It would have helped if you had posted some sample DITA content to show exactly where you insert the indexterm.
I can reproduce the problem on my side with some DITA content which looks like this:
Code: Select all
<section id="section_jqn_pnt_s2b"><title>My
section</title><indexterm>abcdef</indexterm><p>My content</p></section>
https://github.com/dita-ot/dita-ot/issues/2455
so probably using the AntennaHouse commercial PDF processor should remove it.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 152
- Joined: Fri Apr 24, 2015 12:28 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Radu,
Sorry for not providing a proper example, but I thought it was clear from what Benjamin wrote. Our example looks exactly like yours:
We have already changed to Antenna House. Even with Antenna House this problem persists. So it looks as if this is not only an FOP issue.
Thanks,
Christina
Sorry for not providing a proper example, but I thought it was clear from what Benjamin wrote. Our example looks exactly like yours:
Code: Select all
<section><title>test section</title><indexterm>flowers
<indexterm>summer</indexterm></indexterm><p>some text for the test section</p></section>
Thanks,
Christina
oXygen XML Editor 27.1 build 2025041508
DITA OT 3.7.4
DITA OT 3.7.4
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Christina,
My Antenna House installation is acting up this morning so I cannot test with it.
But I did test the classic PDF output without any customizations using the RenderX XEP processor and it does not add that extra spacing between the title and paragraph.
Regards,
Radu
My Antenna House installation is acting up this morning so I cannot test with it.
But I did test the classic PDF output without any customizations using the RenderX XEP processor and it does not add that extra spacing between the title and paragraph.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 152
- Joined: Fri Apr 24, 2015 12:28 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Radu,
I've just found that in the index.xsl file (org.dita.pdf2), the following template seems to influence this:
Our customized template looks like this:
In our customized template, I've changed the <fo:inline> element to <fo:wrapper> - and that WORKS! I don't know why, but it works. 
Please tell me that it's OK to do this. It seems that our PDF output hasn't changed in any other way, apart from the fact that the empty spaces between section titles and text have disappeared.
Regards,
Christina
I've just found that in the index.xsl file (org.dita.pdf2), the following template seems to influence this:
Code: Select all
<xsl:template match="opentopic-index:index.entry">
<xsl:for-each select="opentopic-index:refID[last()]">
<fo:inline index-key="{@value}"/>
</xsl:for-each>
<xsl:apply-templates/>
</xsl:template>
Code: Select all
<xsl:template match="opentopic-index:index.entry">
<xsl:for-each select="opentopic-index:refID[not(following-sibling::opentopic-index:index.entry)][last()]">
<fo:inline index-key="{@value}"/>
</xsl:for-each>
<xsl:apply-templates/>
</xsl:template>

Please tell me that it's OK to do this. It seems that our PDF output hasn't changed in any other way, apart from the fact that the empty spaces between section titles and text have disappeared.
Regards,
Christina
oXygen XML Editor 27.1 build 2025041508
DITA OT 3.7.4
DITA OT 3.7.4
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: PDF output: <indexterm> in sections causes empty row
Hi Christina,
I agree, you should use fo:wrapper instead, I added also an issue on the DITA OT issues list:
https://github.com/dita-ot/dita-ot/issues/3042
Regards,
Radu
I agree, you should use fo:wrapper instead, I added also an issue on the DITA OT issues list:
https://github.com/dita-ot/dita-ot/issues/3042
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Return to “DITA (Editing and Publishing DITA Content)”
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