We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.
I'm trying to change the line distance between TOC lines with the pdf.css. There's no way I have found to adjust this.
I have put the following into every single pdf-toc style, to no avail. The line distance stays about half a line.
If I set everything to 100pt, the distance still is half a line. Putting other colors in etc. works just fine, so I am using the correct styles, it seems.
I'm not using any other CSS as far as I know of. I have unchecked the default.css everywhere. Is there anything else that determines the line distance for TOC lines in the PDF output?
After careful testing, I have found the css styles to affect (the color of) the following:
p.pdf-toc <- the whole TOC line
a.pdf-toc-link <- just the text at the left hand side (this isn't affected by the p color, needs to be set here)
a.pdf-toc-link:after <- the dots (this one is affected by the p color, but can be overridden here)
span.pdf-toc-page-no <- the page number (this one is also affected by the p color)
The -level1 and -level2 variants (etc.) override the global settings above for the specific levels they point at. And just those levels, not the levels below them as well.
Is there a document or page that describes all these styles? They are kind of descriptive but it still takes a lot of trial and error to find out what these styles really mean (I didn't guess for example that the after style meant the dots).
I am seeing the same. I'll see if I can find out more.
There isn't any documentation about the various style definitions that I have seen.
Adobe have come back to me with this information.
For the line spacing between TOC Items:
The default value is 2.0 for line-height of each TOC item.
About PDF Box Model:
I am not sure if there is something similar being used as reference with respect to HTML Box Model. However, as the user figured it out, header grows upwards and footer downwards.
To fit the header in page or align things from header, Margin settings in PDF Preset > PDF section can be changed.
You can also refer to all the .ejs template files being used for PDF Output in “C:\Program Files\Adobe\Adobe RoboHelp 2019\resources\data\pdf” folder.
For example, toc.xsl.ejs file contains default styling information for TOC Items.
Hope that helps.
Yes, that works!
Still not sure why they chose to completely ignore the margin settings for the TOC, because now I can only change the distance evenly-spaced, while I would like to have toc1 with more space above and less space below, to emphasize that is belongs to the block below it and not the block above it.
Maybe in a future upgrade. But for now this will (have to) do 🙂
Thanks Peter for your effort!
For things that are broken or need further functionality, submit a request. Please follow this link to report bugs or request features. https://tracker.adobe.com
Post the link to your bug report / feature request in this thread and others can vote for it. The more people who do so, the higher it gets prioritised.
I initially tried to report it as bug, but the system didn't let me. So here it is as a feature request:
A method I used in Classic was to set the TOC style in my Word template to achieve what I wanted. I haven't tested that in 2019 but it might be worth a try with any further issues that crop up.