Styling with CSS Hovertext in html output
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 38
- Joined: Thu Oct 28, 2010 5:10 pm
Styling with CSS Hovertext in html output
Hello,
I am now able to show the hovertext with the help of oXygen XML support team.
I need to style the hovertext for instance change the background color of the text box from yellow to some different color, adjust the text indentation and padding as well as change the box border properties...
Would you please show me how/where to make the changes for the above properties?
Thanks
I am now able to show the hovertext with the help of oXygen XML support team.
I need to style the hovertext for instance change the background color of the text box from yellow to some different color, adjust the text indentation and padding as well as change the box border properties...
Would you please show me how/where to make the changes for the above properties?
Thanks
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Styling with CSS Hovertext in html output
Post by sorin_ristache »
Hi,
The tooltip appearance is browser dependent. For example in Firefox I have a gray background on the hover text, not yellow. You can however set the text in a different attribute, for example data-title, and set the hover style on that attribute. You can find some details here.
Regards,
Sorin
The tooltip appearance is browser dependent. For example in Firefox I have a gray background on the hover text, not yellow. You can however set the text in a different attribute, for example data-title, and set the hover style on that attribute. You can find some details here.
Regards,
Sorin
-
- Posts: 38
- Joined: Thu Oct 28, 2010 5:10 pm
Re: Styling with CSS Hovertext in html output
Thanks Sorin,
Can you provide a simple example of what you meant in the context of oXygen XML. I have read the reference thread you pointed out in your reply.
Where can I make a change inside the oXygen provided CSS or XSLT to get to style the text like the one you mentioned (data-title).
Thanks
Can you provide a simple example of what you meant in the context of oXygen XML. I have read the reference thread you pointed out in your reply.
Where can I make a change inside the oXygen provided CSS or XSLT to get to style the text like the one you mentioned (data-title).
Thanks
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Styling with CSS Hovertext in html output
Post by sorin_ristache »
Hi,
You can add your CSS customizations for the hover popup style to the CSS file [Oxygen-install-dir]\frameworks\dita\DITA-OT\plugins\com.oxygenxml.webhelp\oxygen-webhelp\resources\css\webhelp_topic.css which is included in every HTML output file of the DITA Webhelp transformation or you can create your own CSS file and set it in the args.css parameter of the DITA Webhelp transformation.
If you want to go the way of adding an attribute data-title to the <a> element corresponding to a glossary term then you have to add this attribute by modifying the template
from file [Oxygen-install-dir]\frameworks\dita\DITA-OT\xsl\xslhtml\dita2htmlImpl.xsl. There is an element <a> with an attribute title="{$hovertext}" constructed inside this XSLT template.
Regards,
Sorin
You can add your CSS customizations for the hover popup style to the CSS file [Oxygen-install-dir]\frameworks\dita\DITA-OT\plugins\com.oxygenxml.webhelp\oxygen-webhelp\resources\css\webhelp_topic.css which is included in every HTML output file of the DITA Webhelp transformation or you can create your own CSS file and set it in the args.css parameter of the DITA Webhelp transformation.
If you want to go the way of adding an attribute data-title to the <a> element corresponding to a glossary term then you have to add this attribute by modifying the template
Code: Select all
<xsl:template match="*[contains(@class,' topic/term ')]" name="topic.term">
Regards,
Sorin
-
- Posts: 10
- Joined: Mon Sep 15, 2014 9:52 am
Re: Styling with CSS Hovertext in html output
Hi,
I use <oXygen/> XML Author 14.2 and the output help that i build is Eclipse and Webhelp.
I would like to show hovertext for some definitions and short descriptions of terms in my output. Could you please explain how to do that?
Thank you
Anuradha
I use <oXygen/> XML Author 14.2 and the output help that i build is Eclipse and Webhelp.
I would like to show hovertext for some definitions and short descriptions of terms in my output. Could you please explain how to do that?
Thank you
Anuradha
-
- Posts: 9446
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Styling with CSS Hovertext in html output
Hi Anuradha,
You probably need to perform some XSLT customization and set the title attribute on the HTML reference with a custom value derived from the shortdescription.
Maybe you could ask about this on the DITA Users List:
https://groups.yahoo.com/neo/groups/dita-users/info
Regards,
Radu
You probably need to perform some XSLT customization and set the title attribute on the HTML reference with a custom value derived from the shortdescription.
Maybe you could ask about this on the DITA Users List:
https://groups.yahoo.com/neo/groups/dita-users/info
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service