rendering latex formula in webhelp
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
rendering latex formula in webhelp
Hi Radu,
As I mentioned in another post in Common Problems section, I installed the dita-latex plugin and get it installed as instructed. It turns out the renderings works well in Author mode of editing environment, either with oxygen v25 or v26. But in the webhelp output, those latex formulas in SVG aren't displayed.
Do I need to modify the plugins.dtd as well?
Attached is a sample dita topic containing a latex formula.
As I mentioned in another post in Common Problems section, I installed the dita-latex plugin and get it installed as instructed. It turns out the renderings works well in Author mode of editing environment, either with oxygen v25 or v26. But in the webhelp output, those latex formulas in SVG aren't displayed.
Do I need to modify the plugins.dtd as well?
image.png
Or do I need to specify some rules for SVG in CSS in the publishing template? Attached is a sample dita topic containing a latex formula.
sma.zip
Thanks!You do not have the required permissions to view the files attached to this post.
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: rendering latex formula in webhelp
Sorry for the delay.
So you probably followed this blog post:
https://blog.oxygenxml.com/topics/addin ... t-dita.htm
Per the blog post there are two plugins you need to install, one for rendering the equation in the Author mode and one for publishing:
So you probably followed this blog post:
https://blog.oxygenxml.com/topics/addin ... t-dita.htm
Per the blog post there are two plugins you need to install, one for rendering the equation in the Author mode and one for publishing:
Did you also install the publishing plugin?Publishing to HTML-based and PDF outputs. This DITA Open Toolkit plugin automatically converts LaTeX images to SVG when publishing: https://github.com/oxygenxml/dita-latex.
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
Re: rendering latex formula in webhelp
Hi Radu,
Yes, as instructions from https://blog.oxygenxml.com/topics/addin ... -dita.html went, I copied the latex-images-support plugin to \Oxygen XML Editor 26\plugins, this plugin enables the visual effect of latex formula in SVG format when editing in Author mode of oxygen xml editor. It works.
The other plugin for publishing, the one you developed and posted over https://github.com/oxygenxml/dita-latex was installed as "com.oxygenxml.latex.svg" under \Oxygen XML Editor 26\frameworks\dita\DITA-OT\plugins directory.
Does it have anything to do with the JRE? To avoid the transformation failture caused by the internal bug of the bundled OpenJDK 17.00.8 (temurin), I instead, specified the latest Open JDK as JAVA_Home for oxygen v26 (C:\Program Files\Eclipse Adoptium\jre-21.0.0.35-hotspot), which works out fine so far, no obvious bugs.
Another test I took with oxygen v25.1+build-in JRE+the two plugins cannot display the SVG images of Latex formula either. Perhaps I missed something important?
Yes, as instructions from https://blog.oxygenxml.com/topics/addin ... -dita.html went, I copied the latex-images-support plugin to \Oxygen XML Editor 26\plugins, this plugin enables the visual effect of latex formula in SVG format when editing in Author mode of oxygen xml editor. It works.
The other plugin for publishing, the one you developed and posted over https://github.com/oxygenxml/dita-latex was installed as "com.oxygenxml.latex.svg" under \Oxygen XML Editor 26\frameworks\dita\DITA-OT\plugins directory.
Does it have anything to do with the JRE? To avoid the transformation failture caused by the internal bug of the bundled OpenJDK 17.00.8 (temurin), I instead, specified the latest Open JDK as JAVA_Home for oxygen v26 (C:\Program Files\Eclipse Adoptium\jre-21.0.0.35-hotspot), which works out fine so far, no obvious bugs.
Another test I took with oxygen v25.1+build-in JRE+the two plugins cannot display the SVG images of Latex formula either. Perhaps I missed something important?
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: rendering latex formula in webhelp
Hi,
I do not know where the problem is.
In the Oxygen Preferences->"DITA / Logging" page you can set the "Show console output->Always" radio button, then with Oxygen 26.0 run the WebHelp publishing for example on your sample DITA Map containing topics with Latex equations.
At the bottom of Oxygen you should get a "DITA OT" console tab view containing lots of logging information. You can copy that entire content to a file, zip it and then maybe email it to us (support@oxygenxml.com).
Regards,
Radu
I do not know where the problem is.
In the Oxygen Preferences->"DITA / Logging" page you can set the "Show console output->Always" radio button, then with Oxygen 26.0 run the WebHelp publishing for example on your sample DITA Map containing topics with Latex equations.
At the bottom of Oxygen you should get a "DITA OT" console tab view containing lots of logging information. You can copy that entire content to a file, zip it and then maybe email it to us (support@oxygenxml.com).
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
Re: rendering latex formula in webhelp
Hi Radu,
Please find the zipped log caught after the last transformation.
Please find the zipped log caught after the last transformation.
log_202310261836.zip
You do not have the required permissions to view the files attached to this post.
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: rendering latex formula in webhelp
Hi,
That file does not contain what I want to see. You copied those results from the "Problems" tab view.
Assuming that in the Preferences->"DITA / Logging" page you have set the "Show console output->Always" radio button and saved the preferences, then published there should be a "DITA-OT ..." console tab view at the bottom of Oxygen after the transformation finishes. I'm interested in the content from it.
I suggest you use email to send us the logger content, it may contain information that is confidential for you.
Regards,
Radu
That file does not contain what I want to see. You copied those results from the "Problems" tab view.
Assuming that in the Preferences->"DITA / Logging" page you have set the "Show console output->Always" radio button and saved the preferences, then published there should be a "DITA-OT ..." console tab view at the bottom of Oxygen after the transformation finishes. I'm interested in the content from it.
I suggest you use email to send us the logger content, it may contain information that is confidential for you.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
Re: rendering latex formula in webhelp
Hi Radu,
I've sent you (support@oxygenxml.com) an email with subject starts with "To Radu: ". I copied the logs from DITA-OT console after generating a webhelp page for a single function description document. This document has been simplified for testing and it's attached in the zip file as well.
Thank you!
I've sent you (support@oxygenxml.com) an email with subject starts with "To Radu: ". I copied the logs from DITA-OT console after generating a webhelp page for a single function description document. This document has been simplified for testing and it's attached in the zip file as well.
Thank you!
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: rendering latex formula in webhelp
Hi,
Thanks for the details you sent me via email.
If you look at the console log you attached for me, after the first line "[echo] dita.plugin.com.elovirta.ooxml.dir" the console log outputs all installed plugins, something like:
The "com.oxygenxml.latex.svg" plugin is not in that list so you have not properly installed it in the "D:\oxygen\Oxygen XML Editor 26\frameworks\dita\DITA-OT\plugins" folder.
Can you double check that in the DITA OT plugins folder you have a subfolder named "com.oxygenxml.latex.svg" containing inside itself the plugin.xml and all other plugin resources?
If so can you run the DITA OT integrator transformation scenario?
https://www.oxygenxml.com/doc/versions/ ... n_scenario
Does it report any error when integrating the plugin?
Regards,
Radu
Thanks for the details you sent me via email.
If you look at the console log you attached for me, after the first line "[echo] dita.plugin.com.elovirta.ooxml.dir" the console log outputs all installed plugins, something like:
Code: Select all
[echo] dita.plugin.com.elovirta.ooxml.dir=D\:\\oxygen\\Oxygen XML Editor 26\\frameworks\\dita\\DITA-OT\\plugins\\com.elovirta.ooxml
[echo] dita.plugin.com.elovirta.pdf.dir=D\:\\oxygen\\Oxygen XML Editor 26\\frameworks\\dita\\DITA-OT\\plugins\\com.elovirta.pdf
[echo] dita.plugin.com.oxygenxml.common.dir=D\:\\oxygen\\Oxygen XML Editor 26\\frameworks\\dita\\DITA-OT\\plugins\\com.oxygenxml.common
[echo] dita.plugin.com.oxygenxml.dita-ot.plugin.mathml.dir=D\:\\oxygen\\Oxygen XML Editor 26\\frameworks\\dita\\DITA-OT\\plugins\\mathml
[echo] dita.plugin.com.oxygenxml.dita.metrics.report.dir=D\:\\oxygen\\Oxygen XML Editor 26\\frameworks\\dita\\DITA-OT\\plugins\\com.oxygenxml.di....
......
Can you double check that in the DITA OT plugins folder you have a subfolder named "com.oxygenxml.latex.svg" containing inside itself the plugin.xml and all other plugin resources?
If so can you run the DITA OT integrator transformation scenario?
https://www.oxygenxml.com/doc/versions/ ... n_scenario
Does it report any error when integrating the plugin?
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
Re: rendering latex formula in webhelp
Hi Radu,
I realised I didn't import the plugin through Run DITA-OT Integrator, that's the step I was missing.
Then I did so just now, the ANT(Run DITA-OT Integrator) console showed the following:
...
integrate:
[integrate] Added com.oxygenxml.latex.svg
configuration-jar:
[jar] Building jar: D:\oxygen\Oxygen XML Editor 26\frameworks\dita\DITA-OT\lib\dost-configuration.jar
BUILD SUCCESSFUL
Total time: 4 seconds
The process finished with exit code: 0
The integration succeeded in both Oxy v25.1 (default JRE) and Oxygen v26 (with Open JDK 21 the latest ).
After a restart, I tried to build the simple dita file that contains an svg latex formula in both oxygen v25 and v26, it turned out that v25 with default jre is totally ok with your plugin, the svg image is displayed in the webhelp output. In v26, transformation runs for a few minutes and hang .. without errors or warnings. I guess it's because of the Open JDK 21. But I can't switch back to Open JDK 17.0.8 temurin which brings lots of errors (hope there's a patch in the future so I can continue with oxygen v26, lots of cool features to be honest.) I'll then use oxygen v25 for the time being.
Thank you Radu!
I realised I didn't import the plugin through Run DITA-OT Integrator, that's the step I was missing.
Then I did so just now, the ANT(Run DITA-OT Integrator) console showed the following:
...
integrate:
[integrate] Added com.oxygenxml.latex.svg
configuration-jar:
[jar] Building jar: D:\oxygen\Oxygen XML Editor 26\frameworks\dita\DITA-OT\lib\dost-configuration.jar
BUILD SUCCESSFUL
Total time: 4 seconds
The process finished with exit code: 0
The integration succeeded in both Oxy v25.1 (default JRE) and Oxygen v26 (with Open JDK 21 the latest ).
After a restart, I tried to build the simple dita file that contains an svg latex formula in both oxygen v25 and v26, it turned out that v25 with default jre is totally ok with your plugin, the svg image is displayed in the webhelp output. In v26, transformation runs for a few minutes and hang .. without errors or warnings. I guess it's because of the Open JDK 21. But I can't switch back to Open JDK 17.0.8 temurin which brings lots of errors (hope there's a patch in the future so I can continue with oxygen v26, lots of cool features to be honest.) I'll then use oxygen v25 for the time being.
Thank you Radu!
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: rendering latex formula in webhelp
Hi,
I'm glad this works for you!
I will try to at least check if the crash was reported to Open JDK.
Regards,
Radu
I'm glad this works for you!
Strange, maybe in the Oxygen Preferences->"DITA Logging" page you can switch to "Show console output->Always" and then run the transformation to see in the console in what step it seems to block.... In v26, transformation runs for a few minutes and hang .. without errors or warnings. I guess it's because of the Open JDK 21.
You mean this thread: post72464.html?hilit=temurin#p72464But I can't switch back to Open JDK 17.0.8 temurin which brings lots of errors (hope there's a patch in the future so I can continue with oxygen v26, lots of cool features to be honest.) I'll then use oxygen v25 for the time being.
I will try to at least check if the crash was reported to Open JDK.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 115
- Joined: Mon Jul 10, 2023 11:49 am
Re: rendering latex formula in webhelp
I will but sometimes later this week because I have uninstalled oxygen 26 from disk yesterday...xygen Preferences->"DITA Logging" page you can switch to "Show console output->Always" and then run the transformation to see in the console in what step it seems to block...
Yes, I used to be a software tester before becoming a tech writer, so I had several tests with openJDK 17.0.9, 17.0.8 and 17.0.6 downloaded from here: https://adoptium.net/zh-CN/temurin/archive/?version=17, all of them have the same problem with EXCEPTION_ACCESS_VIOLATION errors. As Adrian said here (post72457.html#p72457), it might relate to the java runtime requirements of build-in DITA-OT (I don't know which DITA-OT variant oxygen v26 is bundled with) or a specified DITA-OT.You mean this thread: post72464.html?hilit=temurin#p72464
I will try to at least check if the crash was reported to Open JDK.
But specifying an external DITA-OT for oxygen xml editor, for example, the latest DITA-OT 4.X, might cause some other compatibility issues when transforming documents from oxygen, as some features of oxygen might have dependencies on certain DITA-OT version (or built-in DITA-OT). There's always some trade-off.
-
- Posts: 6
- Joined: Tue May 18, 2021 1:00 pm
Re: rendering latex formula in webhelp
Galano Han
I have browsed through many of the posts you made with great interest.
Are you considering Oxygen XML Editor/Author/Feedback line of products for your business?
As a VAR of Oxygen, we are here to help you.
In fact, some of our Chinese Oxygen customers have faced similar issues as you have reported here, and with our support, they managed to solve them. For example, visit:
- https://help.yeastar.com/en/p-series-appliance-edition/
- https://www.goodix.com/en/document/center
By the way, I find your documents nice to read, for example, https://docs.dolphindb.cn/zh/help/Progr ... ts/go.html.
Ray
I have browsed through many of the posts you made with great interest.
Are you considering Oxygen XML Editor/Author/Feedback line of products for your business?
As a VAR of Oxygen, we are here to help you.
In fact, some of our Chinese Oxygen customers have faced similar issues as you have reported here, and with our support, they managed to solve them. For example, visit:
- https://help.yeastar.com/en/p-series-appliance-edition/
- https://www.goodix.com/en/document/center
By the way, I find your documents nice to read, for example, https://docs.dolphindb.cn/zh/help/Progr ... ts/go.html.
Ray
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)
- ↳ 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