Page 1 of 1

"uicontrol" renders differently between projects

Posted: Tue Jan 29, 2019 1:30 am
by Carl
I just discovered something very puzzling.

In our doc set, the previous writers used the "uicontrol" tag to render not just UI controls, but then they started using it as a replacement for the "<b>" tag to bold text. I think it's poor form to do this, but it seemed to work. Now I've discovered a glitch: in most of the PDF transformations, the "uicontrol" text come out as bold, which is to be expected. But I just discovered a PDF in which "uicontrol" did not come out as bold! Rather, it came across as normal paragraph font.

Do you know what might be causing this? I'm using the same PDF transformation as the other documents.

Re: "uicontrol" renders differently between projects

Posted: Tue Jan 29, 2019 9:18 am
by Radu
Hi Carl,

Actually some companies prohibit their tech writers from using <b> and <i> because they have no semantic meaning, they only add styling. So it's correct to use <uicontrol> whenever you refer to actions or commands, menu names which appear in the user interface.
For example here's what the DITA Style Guide has to say about bold and italic:

https://www.oxygenxml.com/dita/stylegui ... omain.html
The elements in the typographic domain are used to describe styling characteristics. They are primarily intended as the basis for specialisation. Avoid using these elements.
Semantic elements should always be used in preference to typographic elements.
Now coming back to your problem, an improperly created PDF customization might lead to <uicontrol> not being rendered as bold in the published output.
At some point I gave a larger explanation to somebody having the same problem:

topic10123.html#p28139

Regards,
Radu