summaryrefslogtreecommitdiff
path: root/support/TeX4ht/source/tex4ht-mathml.tex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2023-09-21 03:00:44 +0000
committerNorbert Preining <norbert@preining.info>2023-09-21 03:00:44 +0000
commit0bb8ade32dcca6728c583e822cbff37268b73c66 (patch)
tree2c49f3252ce6869dc074c17cb7d0fe8d0996caf3 /support/TeX4ht/source/tex4ht-mathml.tex
parentab5949fa3536e691f573eb3d885927c97281eb9c (diff)
CTAN sync 202309210300
Diffstat (limited to 'support/TeX4ht/source/tex4ht-mathml.tex')
-rw-r--r--support/TeX4ht/source/tex4ht-mathml.tex27
1 files changed, 26 insertions, 1 deletions
diff --git a/support/TeX4ht/source/tex4ht-mathml.tex b/support/TeX4ht/source/tex4ht-mathml.tex
index 869396ddec..9b6f23c04b 100644
--- a/support/TeX4ht/source/tex4ht-mathml.tex
+++ b/support/TeX4ht/source/tex4ht-mathml.tex
@@ -1,4 +1,4 @@
-% $Id: tex4ht-mathml.tex 1366 2023-09-07 10:32:15Z michal_h21 $$
+% $Id: tex4ht-mathml.tex 1371 2023-09-20 12:19:50Z michal_h21 $$
% compile 3 times: latex tex4ht-mathltx
% or xhlatex tex4ht-mathltx "html,3,sections+"
%
@@ -1843,7 +1843,32 @@ Used to be
+Support for the \verb'\mathversion' command. Thanks to Linas Stonys
+for the report and additional testing.
+\<configure mathml fontmath\><<<
+|<mathversion config|>
+>>>
+
+We can configure attributes that will be added to the \verb'<math>' element
+using \verb'\Configure{mathversion-style}' ideally,
+use something like \verb'mathvariant="xxx"'.
+
+\<mathversion config\><<<
+\NewConfigure{mathversion-style}[2]{\expandafter\gdef\csname :mathversion-#1\endcsname{#2}}
+% ToDo: Add support for other mathversions
+\Configure{mathversion-style}{bold}{\a:mathml mathvariant="bold-italic"}
+>>>
+
+Now we can append code to \verb'\mathversion'.
+It will add the mathvariant tag to the \verb'<math>' element.
+
+\<mathversion config\><<<
+\append:defI\mathversion{%
+ % \a:DviMathML is executed at the beginning of math \a:@math is hook for attributes. we need to append out tags to it
+ \Configure{DviMathML}{\append:def\a:@math{\expandafter\csname :mathversion-\math@version\endcsname}}{}%
+}
+>>>
\<plain,latex mathml\><<<
\Configure{afterSUB}{'}{\def\SUB:prime{\SUB:SUP}}