How to style TOC elements - both in the TOC and within the document?
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 59
- Joined: Tue Sep 13, 2022 4:13 pm
How to style TOC elements - both in the TOC and within the document?
Hello everybody!
I would appreciate any help with the following:
My TOC contains 4 levels. Some chapters contain directly in the title of the chapter - sections highlighted by msgph.
1. It is necessary to make sure that this selection is not reset in TOC (now it is reset by default);
2. It is necessary at the 3rd level - in the TOC and inside the document - to change the font size and make it italic. I have tried changing for this, as well as . (Addition question: how to do this for any level?).
But so far nothing has worked.
I would be glad for any advice!
I would appreciate any help with the following:
My TOC contains 4 levels. Some chapters contain directly in the title of the chapter - sections highlighted by msgph.
1. It is necessary to make sure that this selection is not reset in TOC (now it is reset by default);
2. It is necessary at the 3rd level - in the TOC and inside the document - to change the font size and make it italic. I have tried changing
Code: Select all
*[class ~= "map/topicref"]
Code: Select all
*[class ~= topic/topic] > *[class ~= 'topic/title' ]
But so far nothing has worked.
I would be glad for any advice!
-
- Posts: 665
- Joined: Wed Oct 16, 2019 3:47 pm
Re: How to style TOC elements - both in the TOC and within the document?
Post by julien_lacour »
Hello,
I added an issue related to reset inline elements in TOC, I will notify this thread once resolved.
Until then you can repair it by using an XSLT extension, don't worry I already created it and the publishing template declaring it.
I also created a custom.css stylesheet that change the TOC depth to 4 and change the style on the 3rd level on both TOC and Content.
To refer the publishing template, in Oxygen, simply edit the DITA Map PDF - based on HTML5 & CSS scenario, choose the custom.opt file in the Templates tab and run the transformation.
Regards,
Julien
I added an issue related to reset inline elements in TOC, I will notify this thread once resolved.
Until then you can repair it by using an XSLT extension, don't worry I already created it and the publishing template declaring it.
I also created a custom.css stylesheet that change the TOC depth to 4 and change the style on the 3rd level on both TOC and Content.
custom.zip
In order to use the sample you just need to download and unzip it.To refer the publishing template, in Oxygen, simply edit the DITA Map PDF - based on HTML5 & CSS scenario, choose the custom.opt file in the Templates tab and run the transformation.
Regards,
Julien
You do not have the required permissions to view the files attached to this post.
-
- Posts: 59
- Joined: Tue Sep 13, 2022 4:13 pm
Re: How to style TOC elements - both in the TOC and within the document?
Thank you very much, Julien, for your attention to my question,
I'll wait for the solution to the software flaw that you noted ...
Now I tried to apply the settings and there were a problem:
As for the publication template: unfortunately, I saw a strange problem - I suspect that this happened after yesterday, following the advice here , I tried to change the distance from the pictures to their titles (this attempt automatically reset all my settings and export scenarios - I had to manually restore everything): in my scenario settings - the "Templates" tab disappeared! Here is such a strange thing. Previously was...
Therefore, I could not apply your template. Maybe, of course, I'm doing something wrong ... But my tabs there look like this: Parameters - Filters - Advanced - Output (Templates disappeared somewhere).
How can I restore it, maybe you know?
I'll wait for the solution to the software flaw that you noted ...
Now I tried to apply the settings and there were a problem:
As for the publication template: unfortunately, I saw a strange problem - I suspect that this happened after yesterday, following the advice here , I tried to change the distance from the pictures to their titles (this attempt automatically reset all my settings and export scenarios - I had to manually restore everything): in my scenario settings - the "Templates" tab disappeared! Here is such a strange thing. Previously was...
Therefore, I could not apply your template. Maybe, of course, I'm doing something wrong ... But my tabs there look like this: Parameters - Filters - Advanced - Output (Templates disappeared somewhere).
How can I restore it, maybe you know?
-
- Posts: 665
- Joined: Wed Oct 16, 2019 3:47 pm
Re: How to style TOC elements - both in the TOC and within the document?
Post by julien_lacour »
Hello,
The new Oxygen 25.1 is out, in this version we correct the inline elements behavior in TOC.
Regards,
Julien
The new Oxygen 25.1 is out, in this version we correct the inline elements behavior in TOC.
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