Page 1 of 1

Normalizing spaces in glossary hovertip text (webhelp)

Posted: Mon Oct 06, 2014 1:41 pm
by Rodrik
The hovertip text that is created for glossary entries in the webhelp output includes extraneous spaces and returns. I looked in the dita2htmlImpl.xsl file but in spite of finding the template

Code: Select all

<xsl:template match="*[contains(@class, ' topic/term ')]" name="topic.term">
I couldn't figure out where there might be a missing normalize-space.

I'd appreciate your help.

Regards

Rodrik

Re: Normalizing spaces in glossary hovertip text (webhelp)

Posted: Wed Oct 08, 2014 3:05 pm
by sorin_ristache
Hi Rodrik,

In order to remove the spaces from the tooltip text of glossary terms you should add a normalize-space() call on the line 1429 where the XHTML link to the glossary term is created, which means you should replace the line:

Code: Select all

<a href="{$updatedTarget}" title="{$hovertext}">
with the line:

Code: Select all

<a href="{$updatedTarget}" title="{normalize-space($hovertext)}">

Re: Normalizing spaces in glossary hovertip text (webhelp)

Posted: Wed Oct 08, 2014 5:24 pm
by Rodrik
Perfect. Thank you very much.