Link underlining and descenders in PDF output

Post here questions and problems related to editing and publishing DITA content.
davenz
Posts: 26
Joined: Mon Mar 11, 2019 11:53 am

Link underlining and descenders in PDF output

Post by davenz »

Hi all,

I want to change some aspects of PDF output for better quality. I've attached a screenshot that shows the problems.
descenders.png
descenders.png (41.37 KiB) Viewed 1398 times
1. The two highlighted areas show some strange underline formatting that surrounds the automatic numbering for tables and figures.


2. The default underline styling for links overwrites the glyph descenders (which looks messy and will be a problem for non-English languages.) I added this to my CSS for print output but it doesn't change the output:

Code: Select all

a {	
text-decoration-skip-ink: all;
}
(The font family is IBM Plex.)


Any clues about where to look to fix these two problems? I'm using Oxygen XML Editor 22.1.

Thanks,
Dave
julien_lacour
Posts: 495
Joined: Wed Oct 16, 2019 3:47 pm

Re: Link underlining and descenders in PDF output

Post by julien_lacour »

Hello Dave,

I tried to reproduce on my side using <oXygen/> XML Editor 22.1, build 2020100710 and I didn't succeed.
Here is my generated output. You will see the underlined text is ok on my side.
flowers.zip
(236.81 KiB) Downloaded 231 times
Could you indicate which template you are using for your transformation?
You could try to debug your CSS to see if somehow there is no CSS interfering with your customization or the default CSS style-sheets.

Regards,
Julien
julien_lacour
Posts: 495
Joined: Wed Oct 16, 2019 3:47 pm

Re: Link underlining and descenders in PDF output

Post by julien_lacour »

Hello Dave,

I forgot to ask you on which platform you are using Oxygen (Windows/Linux)?
Could you also indicate which PDF Reader you are using? (if it's not Acrobat Reader)

Regards,
Julien
davenz
Posts: 26
Joined: Mon Mar 11, 2019 11:53 am

Re: Link underlining and descenders in PDF output

Post by davenz »

Hi Julien,

Thanks for your reply and example. I'm using Oxygen XML Editor on Windows 10 and the latest version of Acrobat Reader DC.

The formatting that surrounds the table and figure text in your example is indeed fine. I'll dig into my stylesheets and see what could be causing this.

For the font underlining, I see in your example that the underline also overwrites the glyph descenders—you can see here that it overwrites the descender of the parentheses, p, and g:
descenders-2.png
descenders-2.png (24.23 KiB) Viewed 1350 times
Any clue how to fix this?

Thanks,
Dave
julien_lacour
Posts: 495
Joined: Wed Oct 16, 2019 3:47 pm

Re: Link underlining and descenders in PDF output

Post by julien_lacour »

Hello Dave,

Unfortunately this behavior is controlled by another CSS property called 'text-decoration-skip-ink' which is currently not supported by Apache FOP processor used inside Oxygen PDF Chemistry.
By default internet browsers have this property set to auto which means that underlined content will automatically skip glyphs descenders when underlining text (see specification: https://developer.mozilla.org/en-US/doc ... n-skip-ink).

I added a new feature request for analyzing if it is possible to reproduce this behavior on PDF outputs.
I will let you know as soon as we will have an answer to this problem.

Regards,
Julien
davenz
Posts: 26
Joined: Mon Mar 11, 2019 11:53 am

Re: Link underlining and descenders in PDF output

Post by davenz »

Hi Julien,

Thanks for looking into this -- good to know that the behavior is caused by something else upstream.

Cheers,
Dave
Post Reply