Page 1 of 1
Trying to get TOC numbers aligned in the PDF output
Posted: Fri Mar 03, 2017 4:38 pm
by Christine
Hello,
I would like to have the page numbers aligned on the PDF output and I tried many things in my XSL custom configuration file, but all failed.
Is there a specific parameter in "OXYGEN_INSTALL_DIR\frameworks\docbook\xsl\fo\toc.xsl" to mention to have numbers aligned in TOC ?
Many thanks for your help,
Christine
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Mon Mar 06, 2017 5:22 pm
by Radu
Hi Christine,
Maybe you could link to an image showing how the TOC looks like on your side and describe how it would need to look like.
We are not very familiar with Docbook customizations but maybe we can give you a hint...
Regards,
Radu
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Mon Mar 06, 2017 7:24 pm
by Christine
Hi Radu,
You will find below an example of the type of alignment I can get at the level of the numbers on the TOC on my PDF output.
Is it possible to have these numbers (o 2 and 3 digits) vertically aligned?
Many thanks for your help,Rregards,
Christine

Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Mar 07, 2017 9:48 am
by Radu
Hi Christine,
I do not understand. You are showing me a Word document and you are discussing about the PDF TOC.
For example in my tests with the default PDF output the PDF TOC looks like this:
files/toc.png
To me the numbers seem aligned on the right hand side.
Regards,
Radu
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Mar 07, 2017 12:34 pm
by Christine
Hi Radu,
Yes I am sorry for that but I was not able to upload the proper image using BBCode tags as my images are not on the internet and I do not run a webserver.
So this is the most representative image I found on the internet to show the problem I encounter for each PDF output.
The numbers on the TOC seem to be "floating" and they are not aligned on the right as they are on your image.
Regards,
Christine
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Mar 07, 2017 1:36 pm
by Radu
Hi Christine,
I obtained my PDF just by applying the default Docbook to PDF output without any customization.
It might be possible that your problems are derived from using a certain font for the TOC. Possibly when the used font is not monospaced, each figure has a different width and they may not look nice when placed one under the other.
Regards,
Radu
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Mar 07, 2017 6:26 pm
by Christine
Hi Radu,
Thanks for great help : there was a "sans-serif" font type for the TOC in the pdf output custom configuration file. Using a monospaced font involves a better alignment for the figures.
Regards,
Christine
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Thu Jan 03, 2019 11:56 am
by Rushina
Hi Radu,
In the ToC you shared, I need the sections under chapter numbered. Although, I have set the values of section.label.includes.component.label and
section.autolabel parameters to 1, the numbering does not appear in the ToC of generated PDF or HTML.
Here is the sample of what I need. Please help
1. Chapter
1.1 section one
1.2 section two
1.3 section three
1.4 section four
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Jan 08, 2019 10:32 am
by Radu
Hi,
Your reply does not seem to be related to this particular forum thread.
I see you also added a reply here:
topic10067.html
so I will try to answer you there.
Regards,
Radu
Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Jan 08, 2019 12:42 pm
by Rushina
Well, self-help is the best help. I found the solution that you need to edit the Param files at two places to resolve this issue and it's done.

Re: Trying to get TOC numbers aligned in the PDF output
Posted: Tue Jan 08, 2019 12:46 pm
by Rushina
Thank you, Radu. My first time on these forums and the struggle to correct stuff lead to double queries. Incidentally, the struggle also helped me find the answer where I need to change the params values in the parameters list and also in the fo folder. It was simple! Thank you for the support, nevertheless.