Numbering on TOC is not aligned

Here should go questions about transforming XML with XSLT and FOP.
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Numbering on TOC is not aligned

Post by khcy82nvh »

Hi guys

I am using default DITA-OT to generate PDF output . Upon generated, the numberings on Table of Content of PDF output are not aligned very nicely. It looks something like below:

Contents

The test language ........................................49
Cell expression functions....................................50
Built-in actions.........................................60


Are there any solutions to this issue?

Thank you
Radu
Posts: 9051
Joined: Fri Jul 09, 2004 5:18 pm

Re: Numbering on TOC is not aligned

Post by Radu »

Hi,

Oxygen uses the DITA Open Toolkit to publish DITA content to various outputs like XHTML and PDF.

I cannot reproduce this problem using Oxygen 14.1 and a sample DITA Map.
What version of Oxygen are you using?

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

Hi Radu

It's really strange, because I'm using Oxygen 14.1 too.

For your information, I created document structure as follows:
A master DITAMAP,named TA7, contains sub-DITAMAP(s), such as: The test language, Cell expression functions, Built-in actions. Each sub-DITAMAP contains few DITA files.

I am wondering if this structure affects the alignment on Table of Content page when publishing to PDF output.

Thanks
Radu
Posts: 9051
Joined: Fri Jul 09, 2004 5:18 pm

Re: Numbering on TOC is not aligned

Post by Radu »

Hi,

I am not sure what is the problem, probably it can be reproduced for a certain structure of the references.
If you come up with a sample DITA project which has this behavior, you can send it to us (support@oxygenxml.com).

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

Hi Radu

I've posted my sample of working set to support@oxygenxml.com for reproducing this problem.

I'm looking forward to your solution.

Thanks

Regards,
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

I forgot to tell you. I am using Oxygen 14.0, not 14.1 as I told you before

Sorry for that
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Numbering on TOC is not aligned

Post by sorin_ristache »

Hi,

Thank you for the sample files. The misalignment of the Table of Contents entries is strangely large in your PDF result (more than 5 cm) because I can get only a much smaller misalignment (about 2 or 3 pixels) in the PDF transform applied to the same input DITA map. The size of the misalignment may depend on the font metrics computed by the FOP engine on your platform which may vary between different platforms (Windows, Mac Linux, etc). BTW what is the name and version of your platform?

Do you have East Asian Language support enabled in the operating system, which may impose different font metrics than the Western language support?

Can you send us the full content of the DITA Transformation view which includes all the output messages (info, warnings, loggiong, etc.) of the DITA PDF transformation, to see if they are different in my case, and if there is a font metrics anomaly reported in that long list of messages?


Regards,
Sorin
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

sorin wrote:Hi,

Thank you for the sample files. The misalignment of the Table of Contents entries is strangely large in your PDF result (more than 5 cm) because I can get only a much smaller misalignment (about 2 or 3 pixels) in the PDF transform applied to the same input DITA map. The size of the misalignment may depend on the font metrics computed by the FOP engine on your platform which may vary between different platforms (Windows, Mac Linux, etc). BTW what is the name and version of your platform?

Do you have East Asian Language support enabled in the operating system, which may impose different font metrics than the Western language support?

Can you send us the full content of the DITA Transformation view which includes all the output messages (info, warnings, loggiong, etc.) of the DITA PDF transformation, to see if they are different in my case, and if there is a font metrics anomaly reported in that long list of messages?


Regards,
Sorin
Hi,

My current OS: Window 7, 64 bit
Only English language is enabled on my OS.
I already sent to techSupport of Oxygen the DITA Trasnformation log for looking into this issue.

Thanks
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Numbering on TOC is not aligned

Post by sorin_ristache »

Dear Hien Nguyen,

I suspected some FOP formatting errors or warnings in the DITA transform log but I was wrong.

The new version of Apache FOP which we already tested and which we will include in the next version of Oxygen (14.2) fixed this problem of TOC item alignment. I suggest switching to the new Apache FOP by downloading and using a nightly build of Oxygen 14.2 beta. I sent you a download URL for an Oxygen 14.2 beta build by email.


Regards,
Sorin
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

Hi

Your beta build really fixes the misalignment of Table of Content items.

Thanks so much for your valuable feedbacks

Regards,
khcy82nvh
Posts: 17
Joined: Mon Oct 22, 2012 10:59 am

Re: Numbering on TOC is not aligned

Post by khcy82nvh »

Hi

When using the beta build 14.2 solves misalighment of TOC items, I encourtered this problem:

System ID: C:\Users\hien.vinh.nguyen\AppData\Local\Temp\OxygenXMLTemp\ditaTemporaryOutputDir-1352860021075\t1\t2\t3\t4\t5\TA4VS_Help\Topics\TA4VS_Quick_start.dita
Scenario: TA4VS_master (PDF)
Input file: D:\Documentation\src\Branches\TA_7.0\TA4VS_master.ditamap
Engine name: DITA-OT
Severity: error
Description: [DOTX067E]: No string named 'Installation' was found for language 'en'. Add a mapping for the string 'Installation'. The location of this problem was at (File = C:\Users\hien.vinh.nguyen\AppData\Local\Temp\OxygenXMLTemp\ditaTemporaryOutputDir-1352860021075\t1\t2\t3\t4\t5\TA4VS_Help\Topics\TA4VS_Quick_start.dita, Element = section:2)
URL: http://dita-ot.sourceforge.net/readme/D ... __DOTX067E


Although Oxygen annouced so many problems as above, the PDF quality seems still fine.
Do you know what is "No string named 'Installation' was found for language 'en'. Add a mapping for the string 'Installation'" about?
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Numbering on TOC is not aligned

Post by sorin_ristache »

Hi,

I don't get this error with the sample DITA map received from you.

That error message is reported by DITA-OT when it cannot find that word in the i18n files of DITA-OT for the specified language. Usually it is a word needed in a section title (like Contents, Related concepts, Related topics, Related information), fixed labels inserted in the output (like Before you begin, What to do next, About this task), etc. I think you can fix it by adding an element with the key Installation in the file with the i18n translation for the default language - English, that is [Oxygen-install-dir]/frameworks/dita/DITA-OT/xsl/common/strings-en-us.xml, for example:

Code: Select all

<str name="Installation">Your_translation_here</str>

Regards,
Sorin
Post Reply