How to change the default icon in generated PDF

Post here questions and problems related to editing and publishing DITA content.
lhsihan
Posts: 35
Joined: Thu Aug 15, 2019 5:31 pm

How to change the default icon in generated PDF

Post by lhsihan »

Hi experts,
We have one question that we need to customrize the warning icon in generated PDF. We use the DITA Map PDF - based on HTML5 & CSS transformation scenario and set the args.css attribute to the CSS file we have created such like:

Code: Select all

*[class = "- topic/note note warning note_warning"]:before {
    content: url('https://xxxxxxxxx/picture%2Fwarning.png?response-content-disposition=attachment%3Bfilename%3Dwarning.png');
}
Then the result is as below:
1. map.merged.html in dita map output folder: there are two icons before "Warning" word in the HTML file. One icon is our customrized icon, the other is the default one warning icon.

2. generated PDF: there is only one icon before "Warning". And the icon is the default waring icon, and not the one we wanted.

Could you please help us to figure out how to change the default icon in generated PDF.
Thanks a lot.
Dan
Posts: 501
Joined: Mon Feb 03, 2003 10:56 am

Re: How to change the default icon in generated PDF

Post by Dan »

Hello,

Please read about fine tuning your CSS using the browser CSS inspectors:
https://www.oxygenxml.com/doc/versions/ ... ng_the_css

The idea is to determine the element or pseudo element that generates the default warning icon, and set it a display:none property.

Many regards,
Dan
lhsihan
Posts: 35
Joined: Thu Aug 15, 2019 5:31 pm

Re: How to change the default icon in generated PDF

Post by lhsihan »

Hi Dan,
I couldn't figure this out with your instruction. In the .merged.html, I can see both my customrized icon and the default icon for note. So this mean that the CSS element in my own CSS file is correct. But in the genreated PDF file, I couldn't see my own cutomrized icon and only the default one is shown.


Could you please give me one small demo for changing the default icon in generated PDF file and I can try it.
Thanks a lot.
Costin
Posts: 829
Joined: Mon Dec 05, 2011 6:04 pm

Re: How to change the default icon in generated PDF

Post by Costin »

Hello,

You should send a sample file together with the customization CSS that you tried to use to achieve that (change the custom icon) on our support email - support@oxygenxml.com

Regards,
Costin
Costin Sandoi
oXygen XML Editor and Author Support
Post Reply