PDF Output - Having TOC show 4 levels, instead of 3
Oxygen general issues.
-
- Posts: 11
- Joined: Mon Mar 03, 2014 5:11 pm
- Location: Shawnee, KS
PDF Output - Having TOC show 4 levels, instead of 3
With PDF output customization, is there a way to have the Table of Contents go 4 levels deep, instead of 3?
4 Level Example:
As it is now:
Thank you,
Bryan
4 Level Example:
Code: Select all
Account Reconciliation
* Reconciliation EOD
- Standard Procedures
+ Step 1
+ Step 2
+ Step 3
- Holiday Procedures
RCMENU
* Menu Layout
- Header Modifications
- Footer Modifications
RCTRAN
* Menu Layout
As it is now:
Code: Select all
Account Reconciliation
* Reconciliation EOD
- Standard Procedures
- Holiday Procedures
RCMENU
* Menu Layout
- Header Modifications
- Footer Modifications
RCTRAN
* Menu Layout
Bryan
Bryan
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: PDF Output - Having TOC show 4 levels, instead of 3
Post by sorin_ristache »
What type of XML document is the input of the PDF transformation: DocBook, DITA, etc. ? Is it one of the Oxygen predefined document types, which you can see from menu Options -> Preferences -- Document Type Association?
Regards,
Sorin
Regards,
Sorin
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: PDF Output - Having TOC show 4 levels, instead of 3
Post by sorin_ristache »
Adding a parameter for the depth of the Table of Contents was discussed but it was rejected. So there is no parameter for that in the current version but you can increase the TOC depth by increasing the value of the parameter called tocMaximumLevel in the file:
which is set to 4 by default:
Regards,
Sorin
Code: Select all
[Oxygen-install-dir]\frameworks\dita\DITA-OT\plugins\org.dita.pdf2\xsl\fo\topic2fo.xsl
Code: Select all
<xsl:param name="tocMaximumLevel" select="4"/>
Regards,
Sorin
-
- Posts: 2
- Joined: Thu Jan 13, 2022 10:51 pm
Re: PDF Output - Having TOC show 4 levels, instead of 3
I actually was able to find the solution myself. You should add the following script to the CSS to set the TOC dept higher than 3:
*[class ~= "map/topicref"][is-chapter] >
*[class ~= "map/topicref"]:not([is-chapter]) >
*[class ~= "map/topicref"] >
*[class ~= "map/topicref"]{
display:block;
}
I found this in this reference:
http://docplayer.net/190943699-Oxygen-d ... guide.html
*[class ~= "map/topicref"][is-chapter] >
*[class ~= "map/topicref"]:not([is-chapter]) >
*[class ~= "map/topicref"] >
*[class ~= "map/topicref"]{
display:block;
}
I found this in this reference:
http://docplayer.net/190943699-Oxygen-d ... guide.html
Last edited by mmkarimi on Mon Jun 12, 2023 5:59 pm, edited 1 time in total.
-
- Posts: 665
- Joined: Wed Oct 16, 2019 3:47 pm
Re: PDF Output - Having TOC show 4 levels, instead of 3
Post by julien_lacour »
Hello,
I did a test in <oXygen/> XML Editor 24.0, build 2021121518, using args.css.param.numbering=deep, your CSS should look like this:
You should modify your counter declaration to use the above one instead, if you have issues identifying the applied rules, you can debug your CSS.
Regards,
Julien
I did a test in <oXygen/> XML Editor 24.0, build 2021121518, using args.css.param.numbering=deep, your CSS should look like this:
Code: Select all
*[class ~= "map/topicref"][is-chapter] >
*[class ~= "map/topicref"]:not([is-chapter]) >
*[class ~= "map/topicref"] >
*[class ~= "map/topicref"] {
display: block;
}
*[class ~= "map/map"][numbering ^= 'deep'] *[class ~= "map/topicref"][is-chapter]:not([is-part]) > *[class ~= "map/topicref"] > *[class ~= "map/topicref"] *[class ~= "map/topicref"] {
counter-increment: toc-chapter-and-sections;
}
*[class ~= "map/map"][numbering ^= 'deep'] *[class ~= "map/topicref"][is-chapter]:not([is-part]) > *[class ~= "map/topicref"] > *[class ~= "map/topicref"] *[class ~= "map/topicref"] > *[class ~= "map/topicmeta"] + *[class ~= "map/topicref"] {
counter-reset: toc-chapter-and-sections;
}
*[class ~= "map/map"][numbering ^= 'deep'] *[class ~= "map/topicref"][is-chapter]:not([is-part]) > *[class ~= "map/topicref"] > *[class ~= "map/topicref"] > *[class ~= "map/topicref"] *[class ~= "map/topicref"] > *[class ~= "map/topicmeta"]:before {
content: counters(toc-chapter-and-sections, ".") ". ";
}
Regards,
Julien
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