uihtml does not render LaTeX equation

3 次查看(过去 30 天)
I have uihtml component in App Designer which points to html documentation.
The line:
<p>My inline math code <span class="math notranslate nohighlight">\(A_\text{c} = (\pi/4) d^2\)</span>.</p>
is rendered properly in web browser as inline equation
but in uihtml component it does nothing.
How to fix that?
  2 个评论
Ramtej
Ramtej 2024-3-20
By default HTML does not support embedded Latex. You need to use external tools like "MathML" or display engine like "MathJax" to render Latex equations.
Pawel Kudela
Pawel Kudela 2024-3-20
Thanks, I will use "MathJax" external library and copy js files.

请先登录,再进行评论。

回答(1 个)

Ishaan Mehta
Ishaan Mehta 2024-9-3
Hi Pawel,
I understand that you wish to add mathematical equations as text on the user interface of an MLAPP application.
You can render LaTeX code by using the "Label" component with its "Interpreter" option set to "latex", as in the image below.
This MathWorks documentation page provides more information on the "interpreter" optoin and the supported TeX markup.
Hope this helps!

类别

Help CenterFile Exchange 中查找有关 Migrate GUIDE Apps 的更多信息

产品


版本

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by