| 1 |
% $Id: tex4ht-mathml.tex 1803 2026-04-27 20:24:49Z michal_h21 $$ |
| 2 |
% compile 3 times: latex tex4ht-mathltx |
| 3 |
% or xhlatex tex4ht-mathltx "html,3,sections+" |
| 4 |
% |
| 5 |
% Copyright 2009-2026 TeX Users Group |
| 6 |
% Copyright 1999-2009 Eitan M. Gurari |
| 7 |
% Released under LPPL 1.3c+. |
| 8 |
% See tex4ht-cpright.tex for license text. |
| 9 |
|
| 10 |
\ifx \HTML\UnDef |
| 11 |
\def\HTML{mathml,html-mml} |
| 12 |
\def\CONFIG{\jobname} |
| 13 |
\def\MAKETITLE{\author{Eitan M. Gurari}} |
| 14 |
\def\next{\input mktex4ht.4ht \endinput} |
| 15 |
\expandafter\next |
| 16 |
\fi |
| 17 |
|
| 18 |
\input{common-code} |
| 19 |
\input{common} |
| 20 |
\input{tex4ht-cpright} |
| 21 |
|
| 22 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 23 |
\chapter{Constructs} |
| 24 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 25 |
|
| 26 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 27 |
\section{The equation Environment} |
| 28 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 29 |
|
| 30 |
|
| 31 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 32 |
\subsection{LaTeX} |
| 33 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 34 |
|
| 35 |
|
| 36 |
\<mathml latex\><<< |
| 37 |
\let\A:equation|=\a:equation |
| 38 |
\let\B:equation|=\b:equation |
| 39 |
\let\C:equation|=\c:equation |
| 40 |
\Configure{equation} |
| 41 |
{\A:equation|<math display in equation|>} |
| 42 |
{\B:equation}{\C:equation} |
| 43 |
>>> |
| 44 |
|
| 45 |
\<configure html-mml latex\><<< |
| 46 |
\Configure{equation} |
| 47 |
{\IgnorePar|<inline end-par comment|>\EndP |
| 48 |
\HCode{<table class="equation"><tr><td>}\IgnorePar |
| 49 |
|<math display in equation|>} |
| 50 |
{\ifvmode \IgnorePar\fi\EndP\HCode{</td><td class="eq-no">}} |
| 51 |
{\HCode{</td></tr></table>}|<try inline par|>} |
| 52 |
\Css{.equation td{text-align:center; vertical-align:middle; }} |
| 53 |
\Css{td.eq-no{ width:5\%; }} |
| 54 |
\Css{table.equation { width:100\%; } } |
| 55 |
>>> |
| 56 |
|
| 57 |
\<math display in equation\><<< |
| 58 |
\Configure{$$} |
| 59 |
{\Configure{@math}{|<block display|>% |
| 60 |
\mml:class="equation"}\IgnorePar\EndP\DviMath} |
| 61 |
{\EndDviMath\EndP} |
| 62 |
{\DisplayMathtrue}% |
| 63 |
>>> |
| 64 |
|
| 65 |
|
| 66 |
|
| 67 |
\<block display\><<< |
| 68 |
%\a:mathml |
| 69 |
display="block" |
| 70 |
>>> |
| 71 |
|
| 72 |
|
| 73 |
\<inline display\><<< |
| 74 |
%\a:mathml |
| 75 |
display="inline" |
| 76 |
>>> |
| 77 |
|
| 78 |
|
| 79 |
|
| 80 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 81 |
\subsection{AmsMath} |
| 82 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 83 |
|
| 84 |
|
| 85 |
|
| 86 |
\<amsmath mathml\><<< |
| 87 |
\Configure{equation} |
| 88 |
{\Configure{gather} |
| 89 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" |
| 90 |
\mml:class="equation"><\a:mathml mtr><\a:mathml mtd>}\IgnorePar } |
| 91 |
{\HCode{</\a:mathml mtd></\a:mathml mtr></\a:mathml mtable>}} |
| 92 |
{} |
| 93 |
{} |
| 94 |
{\ifnum\HCol=2 \IgnorePar |
| 95 |
\HCode{</\a:mathml mtd><\a:mathml mtd>}\fi } |
| 96 |
{} |
| 97 |
}{}{} |
| 98 |
\Css{.equation-star td{text-align:center; vertical-align:middle; }} |
| 99 |
\Css{table.equation-star { width:100\%; } } |
| 100 |
>>> |
| 101 |
|
| 102 |
Amsmath uses empty mathopen at the beginning of an equation, and it discards some |
| 103 |
tokens. This results in missing markup for subsequent numbers and characters. |
| 104 |
|
| 105 |
\<amsmath mathml\><<< |
| 106 |
|<alt mathopen for eq|> |
| 107 |
% fix \mathopen inside equation |
| 108 |
\Configure{@begin}{equation}{|<mathopen in equation|>} |
| 109 |
>>> |
| 110 |
|
| 111 |
\<amsmath html-mml pre 2000\><<< |
| 112 |
% pre 2000 |
| 113 |
\Configure{equation} |
| 114 |
{\ifvmode \IgnorePar\fi \EndP |
| 115 |
\HCode{<table class="equation"><tr><td>}% |
| 116 |
|<amsmath equation pre 2000|>% |
| 117 |
\IgnorePar |
| 118 |
} |
| 119 |
{\ifvmode \IgnorePar\fi\EndP \HCode{</td><td class="eq-no">}} |
| 120 |
{\ifvmode \IgnorePar\fi\EndP \HCode{</td></tr></table>}% |
| 121 |
\IgnoreIndent\par} |
| 122 |
\Configure{equation*} |
| 123 |
{\ifvmode \IgnorePar\fi \EndP |
| 124 |
\HCode{<table class="equation-star"><tr><td>}% |
| 125 |
|<amsmath equation pre 2000|>% |
| 126 |
\IgnorePar |
| 127 |
} |
| 128 |
{\ifvmode \IgnorePar\fi\EndP \HCode{</td></tr></table>}% |
| 129 |
\IgnoreIndent\par} |
| 130 |
>>> |
| 131 |
|
| 132 |
|
| 133 |
\<amsmath html-mml jan 2000\><<< |
| 134 |
% jan 2000 |
| 135 |
\Configure{equation} |
| 136 |
{\ifvmode \IgnorePar\fi \EndP |
| 137 |
\HCode{<table class="equation"><tr><td>}% |
| 138 |
|<amsmath equation jan 2000|>% |
| 139 |
\IgnorePar |
| 140 |
} |
| 141 |
{\ifvmode \IgnorePar\fi\EndP |
| 142 |
\HCode{</td><td class="eq-no">}% |
| 143 |
} |
| 144 |
{\ifvmode \IgnorePar\fi\EndP |
| 145 |
\HCode{</td></tr></table>}% |
| 146 |
\IgnoreIndent\par} |
| 147 |
\Configure{equation*} |
| 148 |
{\ifvmode \IgnorePar\fi \EndP |
| 149 |
\HCode{<table class="equation-star"><tr><td>}% |
| 150 |
|<amsmath equation jan 2000|>% |
| 151 |
\IgnorePar |
| 152 |
} |
| 153 |
{\ifvmode \IgnorePar\fi\EndP |
| 154 |
\HCode{</td></tr></table>}% |
| 155 |
\IgnoreIndent\par} |
| 156 |
>>> |
| 157 |
|
| 158 |
|
| 159 |
\<amsmath html-mml july 2000\><<< |
| 160 |
\Configure{equation} |
| 161 |
{\ifvmode \IgnorePar\fi\EndP |
| 162 |
\HCode{<table class="equation"><tr><td>}% |
| 163 |
|<amsmath equation july 2000|>% |
| 164 |
|<math display in equation|>% |
| 165 |
} |
| 166 |
{\ifvmode \IgnorePar\fi\EndP |
| 167 |
\HCode{</td><td class="eq-no">}% |
| 168 |
} |
| 169 |
{\ifvmode \IgnorePar\fi\EndP \HCode{</td></tr></table>}% |
| 170 |
\par\ShowPar\noindent} |
| 171 |
\Configure{equation*} |
| 172 |
{\ifvmode \IgnorePar\fi\EndP |
| 173 |
\HCode{<table class="equation-star"><tr><td>}% |
| 174 |
|<amsmath equation july 2000|>% |
| 175 |
|<math display in equation|>% |
| 176 |
} |
| 177 |
{\ifvmode \IgnorePar\fi\EndP \HCode{</td></tr></table>}% |
| 178 |
\ShowPar\IgnoreIndent\par} |
| 179 |
>>> |
| 180 |
|
| 181 |
% <\a:mathml math\Hnewline |
| 182 |
% \csname a:math-xmlns\endcsname \Hnewline display="inline"> |
| 183 |
|
| 184 |
% \HCode{</\a:mathml math>}% |
| 185 |
|
| 186 |
|
| 187 |
|
| 188 |
|
| 189 |
\<amsmath equation jan 2000\><<< |
| 190 |
|<amsmath equation july 2000|>% |
| 191 |
>>> |
| 192 |
|
| 193 |
Current AMSMath uses empty mathopen at the beginning of an equation, |
| 194 |
which results in missing markup for subsequent numbers and characters. |
| 195 |
|
| 196 |
We check for empty parameter, and don't execute configurations when it is empty. |
| 197 |
|
| 198 |
\<alt mathopen for eq\><<< |
| 199 |
\def\eq:mathopen#1{\ifx\relax#1\relax\else\a:mathopen\fi\o:mathopen:{#1}} |
| 200 |
>>> |
| 201 |
|
| 202 |
\<mathopen in equation\><<< |
| 203 |
\let\mathopen\eq:mathopen% |
| 204 |
>>> |
| 205 |
|
| 206 |
|
| 207 |
|
| 208 |
|
| 209 |
|
| 210 |
\<amsmath equation july 2000\><<< |
| 211 |
\Configure{gather} |
| 212 |
{\HCode{<\a:mathml mtable\Hnewline |
| 213 |
\mml:class="equation"><\a:mathml mtr><\a:mathml mtd>}\IgnorePar |
| 214 |
|<math display in equation|>} |
| 215 |
{\HCode{</\a:mathml mtd></\a:mathml mtr></\a:mathml mtable>}} |
| 216 |
{} |
| 217 |
{} |
| 218 |
{\ifnum\HCol=2 \IgnorePar |
| 219 |
\HCode{</\a:mathml mtd><\a:mathml mtd>}\fi } |
| 220 |
{} |
| 221 |
>>> |
| 222 |
|
| 223 |
\<amsmath equation pre 2000\><<< |
| 224 |
\Configure{$$}{}{}{}% |
| 225 |
\Configure{gather} |
| 226 |
{\Configure{$$} |
| 227 |
{\Configure{@math}{\mml:class="equation"}\IgnorePar\EndP\DviMath} |
| 228 |
{\EndDviMath\EndP}% |
| 229 |
{}% |
| 230 |
\IgnorePar |
| 231 |
}{}{}{}{}{} |
| 232 |
>>> |
| 233 |
|
| 234 |
|
| 235 |
|
| 236 |
|
| 237 |
|
| 238 |
|
| 239 |
|
| 240 |
|
| 241 |
|
| 242 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 243 |
\chapter{MathML} |
| 244 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 245 |
%%%%%%%%%%%%%%%%% |
| 246 |
\section{Front Matters} |
| 247 |
%%%%%%%%%%%%%%%%% |
| 248 |
|
| 249 |
|
| 250 |
|
| 251 |
%%%%%%%%%%%%% |
| 252 |
\subsection{DTD} |
| 253 |
%%%%%%%%%%%%% |
| 254 |
|
| 255 |
\<configure mathml Preamble\><<< |
| 256 |
\Configure{PROLOG}{VERSION,DOCTYPE,*XML-STYLESHEET} |
| 257 |
\:CheckOption{no-DOCTYPE} \if:Option |
| 258 |
\Configure{PROLOG}{VERSION,*XML-STYLESHEET} |
| 259 |
\fi |
| 260 |
>>> |
| 261 |
|
| 262 |
|
| 263 |
% \def\mathml:DOCTYPE{|<xhtml+mathml dtd|>} |
| 264 |
|
| 265 |
\<configure html-mml tex4ht\><<< |
| 266 |
\:CheckOption{frames} \if:Option |
| 267 |
\Configure{frames-altDOCTYPE}{|<mathml dtd|>} |
| 268 |
\else |
| 269 |
|<no frames DOCTYPE|> |
| 270 |
\fi |
| 271 |
>>> |
| 272 |
|
| 273 |
|
| 274 |
|
| 275 |
\<no frames DOCTYPE\><<< |
| 276 |
\def\:temp{xhtml} |
| 277 |
\ifx \:DTD\:temp |
| 278 |
|<mathml dtd|> |
| 279 |
\fi |
| 280 |
>>> |
| 281 |
|
| 282 |
% |
| 283 |
|
| 284 |
\<xhtml+mathml dtd\><<< |
| 285 |
PUBLIC |
| 286 |
"-//W3C//DTD XHTML 1.1 plus MathML 2.0//|<dtd lang|>"\Hnewline |
| 287 |
"http://www.w3.org/Math/DTD/mathml2/xhtml-math11-f.dtd" |
| 288 |
>>> |
| 289 |
|
| 290 |
\<mathml dtd\><<< |
| 291 |
\Configure{DOCTYPE}{\HCode |
| 292 |
{<!DOCTYPE html |<xhtml+mathml dtd|>% |
| 293 |
>\Hnewline |
| 294 |
}} |
| 295 |
>>> |
| 296 |
|
| 297 |
\<frames dtd\><<< |
| 298 |
\Configure{DOCTYPE} |
| 299 |
{\HCode{<!DOCTYPE html PUBLIC |
| 300 |
"-//W3C//DTD XHTML 1.0 Frameset//|<dtd lang|>" |
| 301 |
\Hnewline |
| 302 |
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">\Hnewline}} |
| 303 |
>>> |
| 304 |
|
| 305 |
|
| 306 |
|
| 307 |
|
| 308 |
|
| 309 |
DTD to be used. |
| 310 |
|
| 311 |
\begin{description} |
| 312 |
|
| 313 |
|
| 314 |
|
| 315 |
\item [http://www.w3.org/TR/MathML2/dtd/xhtml-math11-f.dtd] |
| 316 |
|
| 317 |
Declares a FPI (Formal Public Identifier) |
| 318 |
``-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN'' for XHTML+MathML. |
| 319 |
The DTD is problematic |
| 320 |
since it contains a processing instruction |
| 321 |
\verb!<?IS10744:arch xhtml ...>! with a colon in the name. XML |
| 322 |
parsers don't allow it when namespaces are enabled. It carries |
| 323 |
revision id `xhtml-1,v 1.1 2000/10/31 19:52:09 davidc Exp'. |
| 324 |
|
| 325 |
\item[http://www.w3.org/Math/DTD/mathml2/xhtml-math11-f.dtd] |
| 326 |
|
| 327 |
Suggested by the MathML |
| 328 |
specification |
| 329 |
http://www.w3.org/TR/2003/REC-MathML2-20031021/appendixa.html. However, the |
| 330 |
DTD incorporates also SVG. It shows revision id |
| 331 |
`xhtml-math11-f.dtd,v 1.16 2003/11/04 13:14:35 davidc Exp' |
| 332 |
|
| 333 |
\item [others] |
| 334 |
|
| 335 |
See SVG specifications |
| 336 |
\end{description} |
| 337 |
|
| 338 |
The DTD |
| 339 |
a "-//W3C//DTD XHTML 1.1 plus MathML |
| 340 |
2.0//EN" is claimed: |
| 341 |
|
| 342 |
|
| 343 |
|
| 344 |
|
| 345 |
|
| 346 |
\<dtd lang\><<< |
| 347 |
\expandafter |
| 348 |
\ifx \csname a:dtd-lang\endcsname\relax EN\else |
| 349 |
\csname a:dtd-lang\endcsname |
| 350 |
\fi |
| 351 |
>>> |
| 352 |
|
| 353 |
|
| 354 |
\<xmlns\><<< |
| 355 |
xmlns="http://www.w3.org/1999/xhtml" |
| 356 |
>>> |
| 357 |
|
| 358 |
|
| 359 |
|
| 360 |
|
| 361 |
|
| 362 |
|
| 363 |
|
| 364 |
|
| 365 |
|
| 366 |
%%%%%%%%%%%%% |
| 367 |
\subsection{???????????} |
| 368 |
%%%%%%%%%%%%% |
| 369 |
|
| 370 |
|
| 371 |
|
| 372 |
|
| 373 |
\<configure mathml Preamble\><<< |
| 374 |
\ifx \a:mathml\:UnDef |
| 375 |
\NewConfigure{mathml}{1} |
| 376 |
\Configure{mathml}{} |
| 377 |
\fi |
| 378 |
\def\mml:class{\a:mathml class} |
| 379 |
>>> |
| 380 |
|
| 381 |
|
| 382 |
\<plain,latex mathml\><<< |
| 383 |
|<nolimit functions|> |
| 384 |
|<limit functions|> |
| 385 |
>>> |
| 386 |
|
| 387 |
|
| 388 |
\<\><<< |
| 389 |
\def\mml:prefix#1{% |
| 390 |
\Configure{mathop}{*}{<\a:mathml mo #1\Hnewline>}{</\a:mathml mo>}% |
| 391 |
{\Configure{mathop}{*}{<\a:mathml mo>}{</\a:mathml mo>}{}}} |
| 392 |
\def\mml:prefix#1{} |
| 393 |
\def\limit:csname{|%form="prefix" |%\mml:class="csname-limit"} |
| 394 |
\def\nolimit:csname{|%form="prefix" |%\mml:class="csname-nolimit"} |
| 395 |
>>> |
| 396 |
|
| 397 |
|
| 398 |
\<nolimit functionsNO\><<< |
| 399 |
\def\:tempb#1{% |
| 400 |
\def\:tempc##11->##2///{\if :##2:% |
| 401 |
\pend:def#1{\mml:prefix \nolimit:csname}\fi}% |
| 402 |
\expandafter\:tempc\meaning#11->///% |
| 403 |
} |
| 404 |
\:tempb\arccos |
| 405 |
\:tempb\arcsin |
| 406 |
\:tempb\arctan |
| 407 |
\:tempb\arg |
| 408 |
\:tempb\cosh |
| 409 |
\:tempb\cos |
| 410 |
\:tempb\coth |
| 411 |
\:tempb\cot |
| 412 |
\:tempb\csc |
| 413 |
\:tempb\deg |
| 414 |
\:tempb\dim |
| 415 |
\:tempb\exp |
| 416 |
\:tempb\hom |
| 417 |
\:tempb\ker |
| 418 |
\:tempb\lg |
| 419 |
\:tempb\ln |
| 420 |
\:tempb\log |
| 421 |
\:tempb\sec |
| 422 |
\:tempb\sinh |
| 423 |
\:tempb\sin |
| 424 |
\:tempb\tanh |
| 425 |
\:tempb\tan |
| 426 |
|<lim inf/sup|> |
| 427 |
>>> |
| 428 |
|
| 429 |
This should provide correct formatting for built-in log function. By default, it is printed |
| 430 |
in italic and without space that would separate it from the following element. |
| 431 |
|
| 432 |
|
| 433 |
\<mathml latex\><<< |
| 434 |
\ExplSyntaxOn |
| 435 |
\def\:tempa#1#2{% these functions must be protected |
| 436 |
\cs_set_protected:Npn\:tempb{\mathop{\PauseMathClass% |
| 437 |
\HCode{<\a:mathml mi~\mml:class="loglike">} #2\HCode{</\a:mathml mi>% |
| 438 |
<\a:mathml mo>&\#x2061;<!--FUNCTION~APPLICATION--></\a:mathml mo>}\EndPauseMathClass% |
| 439 |
}\nolimits |
| 440 |
} |
| 441 |
\HLet#1\:tempb |
| 442 |
} |
| 443 |
\ExplSyntaxOff |
| 444 |
|
| 445 |
\:tempa\log{log} |
| 446 |
\:tempa\lg{lg} |
| 447 |
\:tempa\ln{ln} |
| 448 |
\:tempa\sin{sin} |
| 449 |
\:tempa\arcsin{arcsin} |
| 450 |
\:tempa\sinh{sinh} |
| 451 |
\:tempa\cos{cos} |
| 452 |
\:tempa\arccos{arccos} |
| 453 |
\:tempa\cosh{cosh} |
| 454 |
\:tempa\tan{tan} |
| 455 |
\:tempa\arctan{arctan} |
| 456 |
\:tempa\tanh{tanh} |
| 457 |
\:tempa\cot{cot} |
| 458 |
\:tempa\coth{coth} |
| 459 |
\:tempa\sec{sec} |
| 460 |
\:tempa\csc{csc} |
| 461 |
\:tempa\arg{arg} |
| 462 |
\:tempa\ker{ker} |
| 463 |
\:tempa\dim{dim} |
| 464 |
\:tempa\hom{hom} |
| 465 |
\:tempa\exp{exp} |
| 466 |
\:tempa\deg{deg} |
| 467 |
>>> |
| 468 |
|
| 469 |
\<limit functionsNO\><<< |
| 470 |
\def\:tempb#1{% |
| 471 |
\def\:tempc##11->##2///{\if :##2:% |
| 472 |
\pend:def#1{\mml:prefix \limit:csname}\fi}% |
| 473 |
\expandafter\:tempc\meaning#11->///% |
| 474 |
} |
| 475 |
\:tempb\Pr |
| 476 |
\:tempb\det |
| 477 |
\:tempb\gcd |
| 478 |
\:tempb\inf |
| 479 |
\:tempb\lim |
| 480 |
\:tempb\max |
| 481 |
\:tempb\min |
| 482 |
\:tempb\sup |
| 483 |
>>> |
| 484 |
|
| 485 |
\<lim inf/supNO\><<< |
| 486 |
\def\:tempc{\mml:prefix\limit:csname \mathop{\operator@font lim inf}} |
| 487 |
\HLet\liminf\:tempc |
| 488 |
\def\:tempc{\mml:prefix\limit:csname \mathop{\operator@font lim sup}} |
| 489 |
\HLet\limsup\:tempc |
| 490 |
>>> |
| 491 |
|
| 492 |
|
| 493 |
\<plain,latex mathml\><<< |
| 494 |
\let\A:displaylines|=\a:displaylines |
| 495 |
\let\B:displaylines|=\b:displaylines |
| 496 |
\let\C:displaylines|=\c:displaylines |
| 497 |
\let\D:displaylines|=\d:displaylines |
| 498 |
\Configure{displaylines} |
| 499 |
{\ifmmode |
| 500 |
\def\A:displaylines{\HCode{<\a:mathml mtable |
| 501 |
\mml:class="displaylines">}}% |
| 502 |
\def\B:displaylines{\HCode{</\a:mathml mtable>}}% |
| 503 |
\def\C:displaylines{\HCode{<\a:mathml mtr\Hnewline |
| 504 |
\mml:class="displaylines"><\a:mathml mtd>}}% |
| 505 |
\def\D:displaylines{\HCode{</\a:mathml mtd></\a:mathml mtr>}}% |
| 506 |
\fi |
| 507 |
\A:displaylines} |
| 508 |
{\B:displaylines} {\C:displaylines}{\D:displaylines} |
| 509 |
>>> |
| 510 |
|
| 511 |
|
| 512 |
|
| 513 |
\<mathml m:env\><<< |
| 514 |
\def\m:env#1{\HCode{<\a:mathml mtable |
| 515 |
\mml:class="#1"><\a:mathml mtr><\a:mathml mtd>}% |
| 516 |
\def\endm:env{\HCode |
| 517 |
{</\a:mathml mtd></\a:mathml mtr></\a:mathml mtable>}}} |
| 518 |
>>> |
| 519 |
|
| 520 |
|
| 521 |
|
| 522 |
\<amstex.tex mathml\><<< |
| 523 |
\Configure{pmatrix} |
| 524 |
{\bgroup\m:env{pmatrix}} |
| 525 |
{\endm:env\egroup} |
| 526 |
\Configure{multline} |
| 527 |
{\HCode{<\a:mathml mtable\mml:class="multline">}} |
| 528 |
{\HCode{</\a:mathml mtable>}} |
| 529 |
{\HCode{<\a:mathml mtr\Hnewline\mml:class="multline"><\a:mathml mtd>}} |
| 530 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}} |
| 531 |
\Configure{smallmatrix} |
| 532 |
{\HCode{<\a:mathml mtable\mml:class="smallmatrix">}} |
| 533 |
{\HCode{</\a:mathml mtable>}} |
| 534 |
{\HCode{<\a:mathml mtr\Hnewline\mml:class="smallmatrix">}} |
| 535 |
{\HCode{</\a:mathml mtr>}} |
| 536 |
{\HCode{<\a:mathml mtd\Hnewline\mml:class="smallmatrix">}} |
| 537 |
{\HCode{</\a:mathml mtd>}} |
| 538 |
\Configure{bmatrix} |
| 539 |
{\bgroup\m:env{bmatrix}} |
| 540 |
{\endm:env\egroup} |
| 541 |
\Configure{vmatrix}{\bgroup\m:env{vmatrix}}{\endm:env\egroup} |
| 542 |
\Configure{Vmatrix}{\bgroup\m:env{Vmatrix}}{\endm:env\egroup} |
| 543 |
\Configure{aligned} |
| 544 |
{\HCode{<\a:mathml mtable\mml:class="aligned" \a:mathml displaystyle="true">}} |
| 545 |
{\HCode{</\a:mathml mtable>}} |
| 546 |
{\HCode{<\a:mathml mtr\Hnewline\mml:class="aligned">}} |
| 547 |
{\HCode{</\a:mathml mtr>}} |
| 548 |
{\HCode{<\a:mathml mtd\Hnewline\mml:class="aligned">}} |
| 549 |
{\HCode{</\a:mathml mtd>}} |
| 550 |
\Configure{xalignat} |
| 551 |
{\HCode{<\a:mathml mtable\mml:class="xalignat" \a:mathml displaystyle="true">}} |
| 552 |
{\HCode{</\a:mathml mtable>}} |
| 553 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="xalignat">}} |
| 554 |
{\HCode{</\a:mathml mtr>}} |
| 555 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="xalignat">}} |
| 556 |
{\HCode{</\a:mathml mtd>}} |
| 557 |
\Configure{xxalignat} |
| 558 |
{\HCode{<\a:mathml mtable \mml:class="xxalignat" \a:mathml displaystyle="true">}} |
| 559 |
{\HCode{</\a:mathml mtable>}} |
| 560 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="xxalignat">}} |
| 561 |
{\HCode{</\a:mathml mtr>}} |
| 562 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="xxalignat">}} |
| 563 |
{\HCode{</\a:mathml mtd>}} |
| 564 |
\Configure{alignedat} |
| 565 |
{\HCode{<\a:mathml mtable \mml:class="alignedat" \a:mathml displaystyle="true">}} |
| 566 |
{\HCode{</\a:mathml mtable>}} |
| 567 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="alignedat">}} |
| 568 |
{\HCode{</\a:mathml mtr>}} |
| 569 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="alignedat">}} |
| 570 |
{\HCode{</\a:mathml mtd>}} |
| 571 |
\Configure{gathered} |
| 572 |
{\HCode{<\a:mathml mtable \mml:class="gathered" \a:mathml displaystyle="true">}} |
| 573 |
{\HCode{</\a:mathml mtable>}} |
| 574 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="gathered">}} |
| 575 |
{\HCode{</\a:mathml mtr>}} |
| 576 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="gathered">}} |
| 577 |
{\HCode{</\a:mathml mtd>}} |
| 578 |
>>> |
| 579 |
|
| 580 |
|
| 581 |
\<mathml\><<< |
| 582 |
% mathml.4ht (|version), generated from |jobname.tex |
| 583 |
% Copyright 2009-2025 TeX Users Group |
| 584 |
% Copyright |CopyYear.1999. Eitan M. Gurari |
| 585 |
|<TeX4ht copywrite|> |
| 586 |
>>> |
| 587 |
|
| 588 |
\<html-mml\><<< |
| 589 |
% html-mml.4ht (|version), generated from |jobname.tex |
| 590 |
% Copyright 2009-2026 TeX Users Group |
| 591 |
% Copyright |CopyYear.1999. Eitan M. Gurari |
| 592 |
|<TeX4ht copywrite|> |
| 593 |
>>> |
| 594 |
|
| 595 |
|
| 596 |
|
| 597 |
|
| 598 |
\<configure mathml tex4ht\><<< |
| 599 |
|<tex compiler mathml|> |
| 600 |
|<sub, sup, subsup|> |
| 601 |
|<limits sub, sup, subsup|> |
| 602 |
>>> |
| 603 |
|
| 604 |
|
| 605 |
|
| 606 |
|
| 607 |
|
| 608 |
|
| 609 |
|
| 610 |
|
| 611 |
|
| 612 |
|
| 613 |
\<html4 font decorations\><<< |
| 614 |
\Configure{htf}{0}{+}{<span\Hnewline |
| 615 |
class="}{\%s}{-\%s}{x-x-\%d}{}{">}{</span>}% |
| 616 |
\Configure{htf}{1}{+}{<img\Hnewline |
| 617 |
src="}{" alt="}{" class="}{\%s}{-\%d}{x-x-\%x}{"\xml:empty>}% |
| 618 |
\Configure{htf}{3}{+}{<img\Hnewline |
| 619 |
src="}{" alt="}{" class="\%s-}{\%s}{-\%d}{x-x-\%x}% |
| 620 |
{" style="text-align:middle"\xml:empty>}% |
| 621 |
\Configure{htf}{4}{+}{<small\Hnewline |
| 622 |
class="}{}{}{}{}{small-caps">}{</small>}% |
| 623 |
\Configure{htf}{6}{+}{<u\Hnewline |
| 624 |
class="}{}{}{}{}{underline">}{</u>}% |
| 625 |
\Configure{htf}{8}{+} |
| 626 |
{<sup class="htf"><strong>}{}{}{}{}{}{</strong></sup>}% |
| 627 |
\Configure{htf}{10}{+} |
| 628 |
{<span class="htf-cmbx">}{}{}{}{}{}{</span>}% |
| 629 |
\Configure{htf}{12}{+} |
| 630 |
{<span\Hnewline class="htf-calligraphy">}{}{}{}{}{}{</span>}% |
| 631 |
>>> |
| 632 |
|
| 633 |
\<no html4 font decorations\><<< |
| 634 |
\Configure{htf}{0}{+}{}{}{}{}{}{}{}% |
| 635 |
\Configure{htf}{1}{+}{}{}{}{}{}{}{}% |
| 636 |
\Configure{htf}{3}{+}{}{}{}{}{}{}{}% |
| 637 |
\Configure{htf}{4}{+}{}{}{}{}{}{}{}% |
| 638 |
\Configure{htf}{6}{+}{}{}{}{}{}{}{}% |
| 639 |
\Configure{htf}{8}{+}{}{}{}{}{}{}{}% |
| 640 |
\Configure{htf}{10}{+}{}{}{}{}{}{}{}% |
| 641 |
\Configure{htf}{12}{+}{}{}{}{}{}{}{}% |
| 642 |
>>> |
| 643 |
|
| 644 |
|
| 645 |
|
| 646 |
|
| 647 |
|
| 648 |
\<configure mathml tex4ht\><<< |
| 649 |
\def\mml:htfsym{\Configure |
| 650 |
{htf}{254}{+}{<\a:mathml mglyph\Hnewline fontfamily="}{\%s"}{ |
| 651 |
index="\%s"}{ mathsize="\%d\%\%"}{}{ alt="}{"/>}} |
| 652 |
\def\ext:htfsym{\Configure{htf}{254}{+}{}{}{}{}{}{}{}} |
| 653 |
>>> |
| 654 |
|
| 655 |
|
| 656 |
\<configure mathml-mml tex4ht\><<< |
| 657 |
\append:def\mml:htfsym{|<no html4 font decorations|>} |
| 658 |
\append:def\ext:htfsym{|<html4 font decorations|>} |
| 659 |
>>> |
| 660 |
|
| 661 |
|
| 662 |
We reserve code 254 (and 255) for unknown symbols. |
| 663 |
|
| 664 |
|
| 665 |
|
| 666 |
\<configure mathml latex\><<< |
| 667 |
\:CheckOption{core}\if:Option \expandafter\endinput \fi |
| 668 |
|<mathml latex|> |
| 669 |
|<plain,latex mathml|> |
| 670 |
>>> |
| 671 |
|
| 672 |
\<configure mathml fontmath\><<< |
| 673 |
|<math fonts utilities|> |
| 674 |
|<set mathcal class|> |
| 675 |
|<set mathcal symbols|> |
| 676 |
|<redefine mathcal|> |
| 677 |
|<mathml plain,fontmath|> |
| 678 |
>>> |
| 679 |
|
| 680 |
\<configure mathml plain\><<< |
| 681 |
\:CheckOption{core}\if:Option \expandafter\endinput \fi |
| 682 |
|<mathml plain|> |
| 683 |
|<mathml plain,fontmath|> |
| 684 |
|<plain,latex mathml|> |
| 685 |
>>> |
| 686 |
|
| 687 |
\<mathml plain,fontmath\><<< |
| 688 |
|<rlbabel everypar|> |
| 689 |
|<plain,fontmath math classes|> |
| 690 |
>>> |
| 691 |
|
| 692 |
\<configure mathml amsmath\><<< |
| 693 |
|<arr amsmath, amstex1|> |
| 694 |
|<amsmath mathml|> |
| 695 |
|<amsmath symbols|> |
| 696 |
>>> |
| 697 |
|
| 698 |
\<configure mathml amsmath\><<< |
| 699 |
\Configure{intertext} |
| 700 |
{\IgnorePar \ifinalign@ |
| 701 |
\HCode{\ifnum \HRow>0 </\a:mathml mtd></\a:mathml mtr>\fi |
| 702 |
<\a:mathml mtr><\a:mathml mtd |
| 703 |
columnspan="\ifnum \HRow=0 15\else \HCol\fi" |
| 704 |
\mml:class="intertext">}% |
| 705 |
\else \ifingather@ |
| 706 |
\HCode{<\a:mathml mtr><\a:mathml mtd columnspan="\HCol" |
| 707 |
\mml:class="intertext">}% |
| 708 |
\fi\fi |
| 709 |
\AA:text{intertext}% |
| 710 |
} |
| 711 |
{\BB:text \ifvmode \IgnorePar \fi \EndP\ifinalign@ |
| 712 |
\HCode{</\a:mathml mtd></\a:mathml mtr>% |
| 713 |
\ifnum \HRow>0 <\a:mathml mtr><\a:mathml mtd>\fi}% |
| 714 |
\else \ifingather@ |
| 715 |
\HCode{</\a:mathml mtd></\a:mathml mtr>}% |
| 716 |
\fi\fi |
| 717 |
} |
| 718 |
>>> |
| 719 |
|
| 720 |
|
| 721 |
\<configure mathml amsmath\><<< |
| 722 |
\Configure{boldsymbol}{\bgroup\HCode{<\a:mathml mstyle mathvariant="bold-italic">}}{\HCode{</\a:mathml mstyle>}\egroup} |
| 723 |
>>> |
| 724 |
|
| 725 |
\<configure mathml amsmath\><<< |
| 726 |
\Configure{maketag} |
| 727 |
{\ifmathml |
| 728 |
\ifmtext \expandafter\expandafter\expandafter\no:maketag\fi |
| 729 |
\else \expandafter\no:maketag\fi |
| 730 |
\AA:text{maketag}\hbox\bgroup\:gobbleIII :@:} |
| 731 |
{\egroup\BB:text\ } |
| 732 |
\def\no:maketag#1:@:#2\b:maketag{\hbox{#2}} |
| 733 |
>>> |
| 734 |
|
| 735 |
|
| 736 |
\<configure mathml amstext\><<< |
| 737 |
\Configure{text}{\AA:text{text}}{\BB:text} |
| 738 |
>>> |
| 739 |
|
| 740 |
|
| 741 |
\<amsmath symbols\><<< |
| 742 |
\def\:tempc{\DOTSI\protect\:idotsint} |
| 743 |
\HLet\idotsint|=\:tempc |
| 744 |
\def\:idotsint{% |
| 745 |
\mathop{\intop\cdotp\cdotp\cdotp\intop }\ilimits@ |
| 746 |
} |
| 747 |
>>> |
| 748 |
|
| 749 |
\<configure mathml amsopn\><<< |
| 750 |
|<amsopn / amstex.sty mathml|> |
| 751 |
>>> |
| 752 |
|
| 753 |
\<configure mathml amstex1\><<< |
| 754 |
% amstex.sty |
| 755 |
|<arr amsmath, amstex1|> |
| 756 |
|<amstex.sty mathml|> |
| 757 |
|<amsopn / amstex.sty mathml|> |
| 758 |
>>> |
| 759 |
|
| 760 |
\<configure mathml amstex\><<< |
| 761 |
% amstex.tex |
| 762 |
|<mathml m:env|> |
| 763 |
|<amstex.tex mathml|> |
| 764 |
>>> |
| 765 |
|
| 766 |
\<configure mathml vanilla\><<< |
| 767 |
|<vanilla mathml|> |
| 768 |
>>> |
| 769 |
|
| 770 |
I've calculated the space widths according to |
| 771 |
\Link[https://chenfuture.wordpress.com/2008/03/22/math-spacing-and-length-units/]{}{}Math |
| 772 |
Spacing and Length Units\EndLink\ blog post. |
| 773 |
|
| 774 |
\<plain,latex mathml\><<< |
| 775 |
\let\mathml:on|=\relax |
| 776 |
\Configure{ } |
| 777 |
{\ifmathml \ifmtext \space \else\Tg<\a:mathml mspace |
| 778 |
width="0.33em" \mml:class="nbsp" />\fi |
| 779 |
\else \:nbsp\fi} |
| 780 |
>>> |
| 781 |
|
| 782 |
|
| 783 |
\<mathml latex\><<< |
| 784 |
\Configure{hspace} |
| 785 |
{\ifmathml\ifmtext\else \Tg<\a:mathml mspace width="\the\tmp:dim"/>\fi\fi}{}{ } |
| 786 |
>>> |
| 787 |
|
| 788 |
|
| 789 |
|
| 790 |
|
| 791 |
\<mathml latex\><<< |
| 792 |
\Configure{romannumeral} |
| 793 |
{\ifmathml\ifmtext\else \HCode{<\a:mathml mrow \mml:class="romannumeral">}\fi\fi} |
| 794 |
{\ifmathml\ifmtext\else \HCode{</\a:mathml mrow>}\fi\fi} |
| 795 |
>>> |
| 796 |
|
| 797 |
\<configure html-mml latex\><<< |
| 798 |
\Configure{romannumeral} |
| 799 |
{\ifmtext\else |
| 800 |
\HCode{<\ifmathml \a:mathml mrow \else span \fi \mml:class="romannumeral">}\fi |
| 801 |
} |
| 802 |
{\ifmtext\else \HCode{</\ifmathml \a:mathml mrow\else span\fi>}\fi } |
| 803 |
>>> |
| 804 |
|
| 805 |
|
| 806 |
\<configure html-mml latex\><<< |
| 807 |
\Configure{hspace} |
| 808 |
{\ifmathml \ifmtext \else \Tg<\a:mathml mspace width="\the\tmp:dim"/>\fi\fi} |
| 809 |
{}{\ifmathml \else \:nbsp\fi} |
| 810 |
>>> |
| 811 |
|
| 812 |
|
| 813 |
\<configure html-mml plain\><<< |
| 814 |
|<plain,latex html-mml|> |
| 815 |
>>> |
| 816 |
|
| 817 |
|
| 818 |
\<configure html-mml latex\><<< |
| 819 |
|<plain,latex html-mml|> |
| 820 |
>>> |
| 821 |
|
| 822 |
\<plain,latex mathml\><<< |
| 823 |
|
| 824 |
% redefine macro from unicode.4ht to produce better accents |
| 825 |
\def\unicode:mathop#1{\PauseMathClass\HCode{<\a:mathml mo accent="true">}#1\HCode{</\a:mathml mo>}\EndPauseMathClass} |
| 826 |
|
| 827 |
\:CheckOption{new-accents} \if:Option \else |
| 828 |
\Configure{accent}\widetilde\widetilde{{}{}} |
| 829 |
{} |
| 830 |
{\HCode{<\a:mathml mover\Hnewline accent="true"><\a:mathml mrow\Hnewline>}#2\HCode{</\a:mathml mrow>}% |
| 831 |
\:widetilde:over \HCode{</\a:mathml mover>}} |
| 832 |
% this configuration caused problems with text accents. |
| 833 |
% we can use Unicode characters with tilde accents instead even in MathML |
| 834 |
% \Configure{accent}\tilde\tilde{{}{}} |
| 835 |
% {} |
| 836 |
% {\HCode{<\a:mathml mover\Hnewline accent="true"><\a:mathml mrow\Hnewline>}#2\HCode{</\a:mathml mrow>}% |
| 837 |
% \:tilde:over \HCode{</\a:mathml mover>}} |
| 838 |
\Configure{accent}\widehat\widehat{{}{}} |
| 839 |
{} |
| 840 |
{\HCode{<\a:mathml mover\Hnewline accent="true"><\a:mathml mrow\Hnewline>}#2\HCode{</\a:mathml mrow>}% |
| 841 |
\:widehat:over \HCode{</\a:mathml mover>}} |
| 842 |
\fi |
| 843 |
>>> |
| 844 |
|
| 845 |
\<plain,latex html-mml\><<< |
| 846 |
\:CheckOption{new-accents} \if:Option \else |
| 847 |
\ifx \mathml:on\:UnDef |
| 848 |
\Configure{accents} |
| 849 |
{\ifmmode \expandafter\mathord\fi |
| 850 |
{|<temp hcode accents|>% |
| 851 |
\ht:special{t4ht@[}\if!#1!x\else#2\fi\ht:special{t4ht@]}}} |
| 852 |
{\ifmmode |
| 853 |
\Tg<\a:mathml mrow |
| 854 |
\mml:class="accent#1">\mathord{#3}\Tg</\a:mathml mrow>% |
| 855 |
\else \HCode{<span class="accent#1">}#3\HCode{</span>}% |
| 856 |
\fi |
| 857 |
}% |
| 858 |
\fi |
| 859 |
\fi |
| 860 |
>>> |
| 861 |
|
| 862 |
|
| 863 |
|
| 864 |
\<plain,latex mathml\><<< |
| 865 |
\:CheckOption{new-accents} \if:Option \else |
| 866 |
\ifx \mathml:on\:UnDef |
| 867 |
\Configure{accents} |
| 868 |
{\ifmmode \expandafter\mathord\fi |
| 869 |
{|<temp hcode accents|>% |
| 870 |
\ht:special{t4ht@[}\if!#1!x\else#2\fi\ht:special{t4ht@]}}} |
| 871 |
{\Tg<\a:mathml mrow |
| 872 |
\mml:class="accent#1">\mathord{#3}\Tg</\a:mathml mrow>% |
| 873 |
}% |
| 874 |
\fi |
| 875 |
\fi |
| 876 |
>>> |
| 877 |
|
| 878 |
|
| 879 |
|
| 880 |
|
| 881 |
|
| 882 |
|
| 883 |
|
| 884 |
\<temp hcode accents\><<< |
| 885 |
\leavevmode |
| 886 |
\if !#1!\ht:special{t4ht@+\string&{35}x#2;}% |
| 887 |
\else \expandafter \ifx\csname U#2#1\endcsname\relax |
| 888 |
\ht:special{t4ht@+\string&{35}x#2;}% |
| 889 |
\else |
| 890 |
\ht:special{t4ht@+\string&{35}x\csname U#2#1\endcsname;}% |
| 891 |
\fi \fi x% |
| 892 |
>>> |
| 893 |
|
| 894 |
|
| 895 |
The special replaces the `x' character. |
| 896 |
|
| 897 |
|
| 898 |
|
| 899 |
\<plain,latex mathml\><<< |
| 900 |
\let\mml:TeX|=\TeX |
| 901 |
\def\TeX{\ifmathml\ifmtext TeX\else |
| 902 |
\HCode{<\a:mathml mtext |
| 903 |
\mml:class="TeX">TeX</\a:mathml mtext>}\fi\else \mml:TeX\fi} |
| 904 |
>>> |
| 905 |
|
| 906 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 907 |
\subsection{TeX Engine} |
| 908 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 909 |
|
| 910 |
\<sub, sup, subsup\><<< |
| 911 |
\Configure{SUB} |
| 912 |
{\Send{BACK} |
| 913 |
{<\a:mathml msub><\a:mathml mrow\Hnewline>}% |
| 914 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>\trap:base} |
| 915 |
{\Tg</\a:mathml mrow>\TG</\a:mathml msub\Hnewline>} |
| 916 |
\Configure{SUP} |
| 917 |
{\Send{BACK} |
| 918 |
{<\a:mathml msup><\a:mathml mrow\Hnewline>}% |
| 919 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>\trap:base} |
| 920 |
{\Tg</\a:mathml mrow>\TG</\a:mathml msup\Hnewline>} |
| 921 |
\Configure{SUBSUP} |
| 922 |
{\Send{BACK} |
| 923 |
{<\a:mathml msubsup><\a:mathml mrow\Hnewline>}% |
| 924 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>\trap:base} |
| 925 |
{\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>\trap:base} |
| 926 |
{\Tg</\a:mathml mrow>\TG</\a:mathml msubsup\Hnewline>} |
| 927 |
\def\trap:base{{\HCode{}}} |
| 928 |
>>> |
| 929 |
|
| 930 |
The \verb'\trap:base' is to catch empty bases of exponents like, e.g., |
| 931 |
in \verb'$a^{^b}$'. |
| 932 |
|
| 933 |
|
| 934 |
\<mathml Link\><<< |
| 935 |
\LinkCommand\mtxt:link{\a:mathml mtext,% |
| 936 |
xlink:type="simple" |
| 937 |
xmlns:xlink="http://www.w3.org/1999/xlink" |
| 938 |
xlink:href, |
| 939 |
id, \mml:class="label",,} |
| 940 |
\LinkCommand\msp:link{\a:mathml mstyle,% |
| 941 |
xlink:type="simple" |
| 942 |
xmlns:xlink="http://www.w3.org/1999/xlink" |
| 943 |
xlink:href, |
| 944 |
id, \mml:class="label",,} |
| 945 |
\let\M:Link|=\Link |
| 946 |
\def\Link{\ifmathml |
| 947 |
\ifmtext |<end mtext space|>\HCode{</\a:mathml mtext>}% |
| 948 |
\expandafter\expandafter\expandafter\mtxt:link |
| 949 |
\else \expandafter\expandafter\expandafter\msp:link\fi |
| 950 |
\else \expandafter\M:Link\fi} |
| 951 |
\let\M:EndLink|=\EndLink |
| 952 |
\edef\:temp{\catcode`\#=\the\catcode`\#} |
| 953 |
\catcode`\#=12 |
| 954 |
\def\EndLink{\ifmathml |
| 955 |
\ifmtext |<end mtext space|>% |
| 956 |
\Endmtxt:link \HCode{<\a:mathml mtext\Hnewline |
| 957 |
\mml:class="endlabel">}|<start sharp mtext space|>% |
| 958 |
\else \HCode{</\a:mathml mstyle><!--endlabel-->}\fi |
| 959 |
\else \expandafter\M:EndLink\fi} |
| 960 |
\:temp |
| 961 |
>>> |
| 962 |
|
| 963 |
For some unclear reasom Mozilla requests mtext the link. |
| 964 |
|
| 965 |
\begin{verbatim} <mrow xlink:type="simple" |
| 966 |
xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="..."><mtext> |
| 967 |
...</mtext></mrow> \end{verbatim} |
| 968 |
|
| 969 |
|
| 970 |
|
| 971 |
|
| 972 |
\<tex compiler mathml\><<< |
| 973 |
\Configure{DviMath} |
| 974 |
{\a:DviMathML \mathmltrue |
| 975 |
\ifOption{mml-fonts}{}{|%\mml:htfsym|%\NoFonts}% |
| 976 |
\IgnoreRule \HCode{<!--l. |
| 977 |
\the\inputlineno-->}\Tg<\a:mathml math\Hnewline |
| 978 |
\csname a:math-xmlns\endcsname \Hnewline \a:@math>\a:math |
| 979 |
|<sv dvimath par|>\IgnorePar} |
| 980 |
{\Tg</\a:mathml math>\EndIgnoreRule |
| 981 |
\ifOption{mml-fonts}{}{|%\ext:htfsym|%\EndNoFonts}% |
| 982 |
\mathmlfalse \b:DviMathML |<recall dvimath par|>} |
| 983 |
\NewConfigure{DviMathML}{2} |
| 984 |
\NewConfigure{math-xmlns}{1} |
| 985 |
\Configure{math-xmlns} |
| 986 |
{ xmlns="http://www.w3.org/1998/Math/MathML" } |
| 987 |
>>> |
| 988 |
|
| 989 |
|
| 990 |
Pictures inside math expressions needs to use \texttt{annotation-xml}. |
| 991 |
This configuration should work for both \verb|\Picture+{}| and \verb|\includegraphics|. |
| 992 |
|
| 993 |
\<configure html-mml tex4ht\><<< |
| 994 |
\Configure{IMG} |
| 995 |
{\ht:special{t4ht=\ifmathml <\a:mathml semantics><\a:mathml annotation-xml encoding="application/xhtml+xml">\fi<img\Hnewline \ifmathml xmlns="http://www.w3.org/1999/xhtml"\fi\Hnewline src="\a:imgdir }\PauseMathClass} |
| 996 |
{\ht:special{t4ht=" alt="}} |
| 997 |
{" } |
| 998 |
{\ht:special{t4ht=" }} |
| 999 |
{\EndPauseMathClass\ht:special{t4ht=\xml:empty>\ifmathml </\a:mathml annotation-xml></\a:mathml semantics>\fi}} |
| 1000 |
>>> |
| 1001 |
|
| 1002 |
\<configure html-mml tex4ht\><<< |
| 1003 |
\Configure{DviMath} |
| 1004 |
{\a:DviMathML \mathmltrue |
| 1005 |
\ifOption{mml-fonts}{|<mml fonts|>}{|%\mml:htfsym|%\NoFonts}% |
| 1006 |
\IgnoreRule \HCode{<!--l. |
| 1007 |
\the\inputlineno-->}\Tg<\a:mathml math\Hnewline |
| 1008 |
\csname a:math-xmlns\endcsname \Hnewline \a:@math>\a:math |
| 1009 |
|<sv dvimath par|>\IgnorePar} |
| 1010 |
{\Tg</\a:mathml math>\EndIgnoreRule |
| 1011 |
\ifOption{mml-fonts}{|<html fonts|>}{|%\ext:htfsym|%\EndNoFonts}% |
| 1012 |
\mathmlfalse \b:DviMathML |<recall dvimath par|>} |
| 1013 |
\Css{\a:mathml math { text-indent: 0em; }} |
| 1014 |
>>> |
| 1015 |
|
| 1016 |
\<html fonts\><<< |
| 1017 |
\Configure{htf}{0}{+}{<span\Hnewline |
| 1018 |
class="}{\%s}{-\%s}{x-x-\%d}{}{">}{</span>}% |
| 1019 |
>>> |
| 1020 |
|
| 1021 |
\<mml fonts\><<< |
| 1022 |
\Configure{htf}{0}{+}{<\a:mathml mstyle\Hnewline |
| 1023 |
class="}{\%s}{-\%s}{x-x-\%d}{}{">}{</\a:mathml mstyle>}% |
| 1024 |
>>> |
| 1025 |
|
| 1026 |
\<tex compiler mathml\><<< |
| 1027 |
\newif\ifmathml \mathmlfalse |
| 1028 |
\newif\ifmtext \mtextfalse |
| 1029 |
|<mathml Link|> |
| 1030 |
\NewConfigure{math}{1} |
| 1031 |
\NewConfigure{@math}{1} |
| 1032 |
\def\IgnoreRule{\ht:special{t4ht@\string_}} |
| 1033 |
\def\EndIgnoreRule{\ht:special{t4ht@\string_\string_}} |
| 1034 |
\Configure{$$} |
| 1035 |
{\Configure{@math}{|<block display|>}\IgnorePar |
| 1036 |
|<inline end-par comment|>\EndP\DviMath} |
| 1037 |
{\EndDviMath\ShowPar\par{\csname HCondtrue\endcsname\noindent}} |
| 1038 |
{\DisplayMathtrue} |
| 1039 |
\Configure{$} |
| 1040 |
{\Configure{@math}{|<inline display|>}\DviMath} |
| 1041 |
{\EndDviMath}{} |
| 1042 |
\newif\ifDisplayMath \DisplayMathfalse |
| 1043 |
>>> |
| 1044 |
|
| 1045 |
|
| 1046 |
The \verb+\sqrt+ fanction produces a structure of the following form. |
| 1047 |
|
| 1048 |
\begin{verbatim} |
| 1049 |
PUSH |
| 1050 |
PUSH |
| 1051 |
......sqrt et al symbols, possibly with PUSH-POP...... |
| 1052 |
POP |
| 1053 |
PUSH |
| 1054 |
W3: 655361 |
| 1055 |
DOWN3: -1020474 |
| 1056 |
PUT_RULE: height: 26213 |
| 1057 |
length: 1091179 |
| 1058 |
DOWN3: 1020474 |
| 1059 |
PUSH |
| 1060 |
.....body......... |
| 1061 |
POP |
| 1062 |
POP |
| 1063 |
POP |
| 1064 |
\end{verbatim} |
| 1065 |
|
| 1066 |
|
| 1067 |
|
| 1068 |
\<tex compiler mathml\><<< |
| 1069 |
\Configure{radical} |
| 1070 |
{\Tg<\a:mathml msqrt>% |
| 1071 |
\special{t4ht\string~!e<<\a:mathml mrow>}% |
| 1072 |
\special{t4ht\string~!e></\a:mathml mrow></\a:mathml msqrt>}% |
| 1073 |
\special{t4ht\string~!ee/}% |
| 1074 |
\special{t4ht\string~!ese-}% |
| 1075 |
} |
| 1076 |
>>> |
| 1077 |
|
| 1078 |
The following fails when the root symbol is made up |
| 1079 |
from multiple characters. |
| 1080 |
|
| 1081 |
\begin{verbatim} |
| 1082 |
\Configure{radical}{\Tg<\a:mathml msqrt>% |
| 1083 |
\Send{EndGROUP}{2}{}% |
| 1084 |
\Send{GROUP}{3}{<\a:mathml mrow>}% |
| 1085 |
\Send{EndGROUP}{3}% |
| 1086 |
{\tg</\a:mathml mrow>\tg</\a:mathml msqrt>}\special{t4ht@+}} |
| 1087 |
\end{verbatim} |
| 1088 |
|
| 1089 |
|
| 1090 |
|
| 1091 |
|
| 1092 |
\<inline end-par comment\><<< |
| 1093 |
\ifvmode\else \HCode{<!--tex4ht:inline-->}\fi |
| 1094 |
>>> |
| 1095 |
|
| 1096 |
|
| 1097 |
\<?\><<< |
| 1098 |
\def\MathRow#1{% |
| 1099 |
\Configure{\expandafter\:gobble\string#1*}{*}% |
| 1100 |
{<\a:mathml mrow\Hnewline |
| 1101 |
\mml:class="\expandafter\:gobble\string#1">}{</\a:mathml mrow>}% |
| 1102 |
{\Configure{\expandafter\:gobble\string#1}{}{}{}{}}#1}% |
| 1103 |
>>> |
| 1104 |
|
| 1105 |
|
| 1106 |
\<recall dvimath par\><<< |
| 1107 |
\sv:ignore |
| 1108 |
>>> |
| 1109 |
|
| 1110 |
\<sv dvimath par\><<< |
| 1111 |
\edef\sv:ignore{\if:nopar |
| 1112 |
\noexpand\IgnorePar\else \noexpand\ShowPar\fi}% |
| 1113 |
>>> |
| 1114 |
|
| 1115 |
|
| 1116 |
The \verb'\MathRow' requests a \verb'<\a:mathml mrow\Hnewline>...</\a:mathml mrow>', instead of the contributions |
| 1117 |
of \verb'\mathop', \verb'\mathrel',...., for the next parameter. |
| 1118 |
|
| 1119 |
|
| 1120 |
\<tex compiler mathml\><<< |
| 1121 |
\def\:MT{\ifmathml \a:mathml m\fi} |
| 1122 |
\Configure{halignTB}{\HCode{<\:MT table }\halignTBL}{\HCode{>}} |
| 1123 |
\Configure{halignTBL} |
| 1124 |
{t}{} |
| 1125 |
{b}{} |
| 1126 |
{c}{} |
| 1127 |
{} |
| 1128 |
\def\t:HA{\HCode{</\:MT table>}} |
| 1129 |
\def\R:HA{\HCode{<\:MT tr \Hnewline style="vertical-align:baseline">}} |
| 1130 |
\def\r:HA{\HCode{</\:MT tr>}} |
| 1131 |
\def\D:HA{|<td save EndP|>\HCode{<\:MT td |
| 1132 |
\ifnum \HMultispan>1 colspan="\HMultispan"\fi}% |
| 1133 |
\halignTD \HCode{\Hnewline>}} |
| 1134 |
\def\d:HA{\HCode{</\:MT td>}|<td recall EndP|>} |
| 1135 |
>>> |
| 1136 |
|
| 1137 |
\<configure html-mml tex4ht\><<< |
| 1138 |
\Configure{halignTBL} |
| 1139 |
{t}{\ifmathml \HCode{ align="baseline 1" style="|<border lines|>" }\fi} |
| 1140 |
{b}{\ifmathml \HCode{ align="baseline -1" style="|<border lines|>" }\fi} |
| 1141 |
{c}{\ifmathml \HCode{ align="axis" style="|<border lines|>" }\fi} |
| 1142 |
{} |
| 1143 |
>>> |
| 1144 |
|
| 1145 |
|
| 1146 |
%%%%%%%%%%%%%%%%%%%%%%%% |
| 1147 |
\subsection{latex.ltx} |
| 1148 |
%%%%%%%%%%%%%%%% |
| 1149 |
|
| 1150 |
|
| 1151 |
MathML: |
| 1152 |
\begin{verbatim} |
| 1153 |
Authors wishing to encode whitespace characters at the start |
| 1154 |
or end of the content of a token, or in sequences other than a single |
| 1155 |
space, without having them ignored, must use or other |
| 1156 |
`whitespace' non-marking entities as described in Section 6.2.4 |
| 1157 |
[Non-Marking Characters]. |
| 1158 |
\end{verbatim} |
| 1159 |
|
| 1160 |
\<start mtext space\><<< |
| 1161 |
\ht:special{t4ht@,&\#x00A0;}% |
| 1162 |
>>> |
| 1163 |
|
| 1164 |
\<start sharp mtext space\><<< |
| 1165 |
\ht:special{t4ht@, }% |
| 1166 |
>>> |
| 1167 |
|
| 1168 |
\<end mtext space\><<< |
| 1169 |
\ht:special{t4ht@,}% |
| 1170 |
>>> |
| 1171 |
|
| 1172 |
|
| 1173 |
\<configure html-mml latex\><<< |
| 1174 |
\Configure{newline} |
| 1175 |
{\ifmtext |<end mtext space|>\HCode{</\a:mathml mtext><\a:mathml |
| 1176 |
mtext \mml:class="newline">}% |
| 1177 |
|<start mtext space|>% |
| 1178 |
\else \Tg<br\Hnewline class="newline" />\fi} |
| 1179 |
>>> |
| 1180 |
|
| 1181 |
\<mathml latex\><<< |
| 1182 |
\Configure{newline} |
| 1183 |
{|<end mtext space|>\HCode{</\a:mathml mtext\Hnewline><\a:mathml |
| 1184 |
mtext \mml:class="newline">}|<start mtext space|>} |
| 1185 |
>>> |
| 1186 |
|
| 1187 |
|
| 1188 |
|
| 1189 |
\<mathml latex\><<< |
| 1190 |
\Configure{[]} |
| 1191 |
{\Configure{@math}{|<block display|>}\csname a:mathml[]\endcsname |
| 1192 |
\DviMath\Tg<\a:mathml mrow\Hnewline>$$\DisplayMathtrue } |
| 1193 |
{$$\Tg</\a:mathml mrow>\EndDviMath\csname b:mathml[]\endcsname} |
| 1194 |
\Configure{()} |
| 1195 |
{\Configure{@math}{|<inline display|>}\csname a:mathml()\endcsname |
| 1196 |
\DviMath\Tg<\a:mathml mrow\Hnewline>$} |
| 1197 |
{$\Tg</\a:mathml mrow>\EndDviMath\csname b:mathml()\endcsname} |
| 1198 |
\NewConfigure{mathml[]}{2} |
| 1199 |
\NewConfigure{mathml()}{2} |
| 1200 |
|<config array|> |
| 1201 |
>>> |
| 1202 |
|
| 1203 |
\<configure html-mml latex\><<< |
| 1204 |
\Configure{mathml[]} |
| 1205 |
{\edef\MathPar{\ifvmode par-\fi}\IgnorePar\endgraf\EndP |
| 1206 |
\HCode{<div class="\MathPar math-display">}} |
| 1207 |
{\HCode{</div>}|<try inline par|>} |
| 1208 |
\Css{div.math-display, div.par-math-display{text-align:center;}} |
| 1209 |
>>> |
| 1210 |
|
| 1211 |
|
| 1212 |
|
| 1213 |
|
| 1214 |
\<configure mathml rlbabel\><<< |
| 1215 |
\Configure{[]} |
| 1216 |
{\Configure{@math}{|<block display|>}\csname a:mathml[]\endcsname |
| 1217 |
\DviMath\Tg<\a:mathml mrow\Hnewline>$$\DisplayMathtrue } |
| 1218 |
{$$\Tg</\a:mathml mrow>\EndDviMath\csname b:mathml[]\endcsname |
| 1219 |
\if@rl\else\beginR\fi } |
| 1220 |
>>> |
| 1221 |
|
| 1222 |
|
| 1223 |
|
| 1224 |
|
| 1225 |
|
| 1226 |
\<configure mathml array\><<< |
| 1227 |
|<config array|> |
| 1228 |
>>> |
| 1229 |
|
| 1230 |
\<configure html-mml array\><<< |
| 1231 |
|<fix first tabular hline|> |
| 1232 |
>>> |
| 1233 |
|
| 1234 |
\<config array\><<< |
| 1235 |
\let\columnlines\empty |
| 1236 |
\Configure{halignTB<>}{array}{\HCode{\Hnewline |
| 1237 |
\a:mathml equalrows="false" |
| 1238 |
\ifx\columnlines\empty\else\a:mathml columnlines="\columnlines" \fi |
| 1239 |
\a:mathml equalcolumns="false" \a:mathml class="array" \a:mathml displaystyle="true"}<>\HAlign} |
| 1240 |
\Configure{array} |
| 1241 |
{\halignTB{array}} |
| 1242 |
{\ifvmode \IgnorePar\fi |<insert Clr|>\Tg</\a:mathml mtable>} |
| 1243 |
{\Tg<\a:mathml mtr \mml:class="array-row">}{\Tg</\a:mathml mtr>} |
| 1244 |
{|<mtd array|>} |
| 1245 |
{\Tg</\a:mathml mtd>} |
| 1246 |
\ConfigureEnv{array} |
| 1247 |
{\bgroup\Configure{$}{}{}{}} |
| 1248 |
{\egroup} |
| 1249 |
{}{} |
| 1250 |
>>> |
| 1251 |
|
| 1252 |
|
| 1253 |
|
| 1254 |
|
| 1255 |
\<configure html-mml latex\><<< |
| 1256 |
\ConfigureEnv{array} |
| 1257 |
{\PushStack\Col:Marg\AllColMargins |
| 1258 |
\bgroup\Configure{$}{}{}{}} |
| 1259 |
{\egroup \PopStack\Col:Marg\AllColMargins} |
| 1260 |
{}{} |
| 1261 |
>>> |
| 1262 |
|
| 1263 |
\<configure html-mml array\><<< |
| 1264 |
\ConfigureEnv{array} |
| 1265 |
{\PushStack\Col:Marg\AllColMargins |
| 1266 |
\bgroup\Configure{$}{}{}{}} |
| 1267 |
{\egroup \PopStack\Col:Marg\AllColMargins} |
| 1268 |
{}{} |
| 1269 |
>>> |
| 1270 |
|
| 1271 |
|
| 1272 |
|
| 1273 |
|
| 1274 |
\<mtd array\><<< |
| 1275 |
\HCode{<\a:mathml mtd\Hnewline \mml:class="array-td" |
| 1276 |
\ifnum 1<\HMultispan columnspan="\HMultispan"\fi}% |
| 1277 |
\halignTD \HCode{>}% |
| 1278 |
>>> |
| 1279 |
|
| 1280 |
\<mtd matrix\><<< |
| 1281 |
\HCode{<\a:mathml mtd\Hnewline \mml:class="matrix" |
| 1282 |
\ifnum 1<\HMultispan columnspan="\HMultispan"\fi}% |
| 1283 |
\halignTD \HCode{>}% |
| 1284 |
>>> |
| 1285 |
|
| 1286 |
|
| 1287 |
|
| 1288 |
|
| 1289 |
\<insert Clr\><<< |
| 1290 |
\expandafter\tmp:toks\expandafter{\Clr}% |
| 1291 |
\HCode{<!--\the\tmp:toks-->}% |
| 1292 |
>>> |
| 1293 |
|
| 1294 |
|
| 1295 |
|
| 1296 |
|
| 1297 |
|
| 1298 |
\<mathml latex\><<< |
| 1299 |
\def\:MM{m} |
| 1300 |
\def\mathml:hborder{% |
| 1301 |
\Configure{HBorder} |
| 1302 |
{<\a:mathml mtr\Hnewline \mml:class="array-hline">} |
| 1303 |
{|<mml hline|>} |
| 1304 |
{</\a:mathml mtr>} |
| 1305 |
{<\a:mathml mtr\Hnewline \mml:class="array-cline">} |
| 1306 |
{<\a:mathml mtd></\a:mathml mtd>} |
| 1307 |
{|<mml hline|>} |
| 1308 |
{</\a:mathml mtr>} |
| 1309 |
{<\a:mathml mtr\Hnewline |
| 1310 |
\mml:class="array-vspace" style="font-size:\HBorderspace">} |
| 1311 |
{} |
| 1312 |
{</\a:mathml mtr>} |
| 1313 |
} |
| 1314 |
|
| 1315 |
\mathml:hborder |
| 1316 |
>>> |
| 1317 |
|
| 1318 |
\<configure html-mml latex\><<< |
| 1319 |
\def\:MM{\ifmathml \a:mathml m\fi} |
| 1320 |
\Configure{HBorder} |
| 1321 |
{<\:MM tr\Hnewline |
| 1322 |
\ifmathml \expandafter\mml:class\else class\fi="array-hline">} |
| 1323 |
{\ifmathml|<mml hline|>\else |
| 1324 |
<td></td>\fi} |
| 1325 |
{</\:MM tr>} |
| 1326 |
{<\:MM tr\Hnewline |
| 1327 |
\ifmathml \expandafter\mml:class\else class\fi ="array-cline">} |
| 1328 |
{<\:MM td></\:MM td>} |
| 1329 |
{\ifmathml|<mml hline|>\else |
| 1330 |
<td></td>\fi} |
| 1331 |
{</\:MM tr>} |
| 1332 |
{<\:MM tr\Hnewline |
| 1333 |
\ifmathml \expandafter\mml:class\else class\fi="array-vspace" |
| 1334 |
style="font-size:\HBorderspace">} |
| 1335 |
{<\:MM td\Hnewline>\ifmathml\else\string&\#x00A0;\fi |
| 1336 |
</\:MM td>} |
| 1337 |
{</\:MM tr>} |
| 1338 |
\Configure{halign} |
| 1339 |
{\EndP |
| 1340 |
\PushStack\Table:Stck\TableNo |
| 1341 |
\gHAdvance\Next:TableNo by 1 |
| 1342 |
\global\let\TableNo=\Next:TableNo |
| 1343 |
\halignTB{halign}} |
| 1344 |
{\HCode{</\:MT table>}\PopStack\Table:Stck\TableNo} |
| 1345 |
{\HCode{<\:MT tr \Hnewline}\halignTR |
| 1346 |
\HCode{ id="TBL-\TableNo-\HRow-">}} |
| 1347 |
{\HCode{</\:MT tr>}} |
| 1348 |
{|<td save EndP|> \HCode{<td |
| 1349 |
\ifnum \HMultispan>1 colspan="\HMultispan"\fi}% |
| 1350 |
\halignTD \HCode{\Hnewline |
| 1351 |
id="TBL-\TableNo-\HRow-\HCol">}\ShowPar\par} |
| 1352 |
{\ifvmode \IgnorePar \fi \EndP |
| 1353 |
\HCode{</\:MT td>}|<td recall EndP|>} |
| 1354 |
>>> |
| 1355 |
|
| 1356 |
It seems that Firefox doesn't support MathML styling |
| 1357 |
using element names, but classes works. We need to hide |
| 1358 |
rows produced by hline. |
| 1359 |
|
| 1360 |
\<configure html-mml latex\><<< |
| 1361 |
\Css{.array-hline,.array-cline{ |
| 1362 |
border-top: 1px solid black; |
| 1363 |
height:0px; |
| 1364 |
}} |
| 1365 |
\Css{.array-hline + .array-vspace:last-child{display:none;}} |
| 1366 |
\Css{.hline-mtd, .array-hline td{ |
| 1367 |
display:none |
| 1368 |
}} |
| 1369 |
% why was the following line here? it hides last row even if it contains content |
| 1370 |
% \Css{.array-hline + .array-row:last-child{display:none;}} |
| 1371 |
\Css{.array-hline:first-child{border-bottom:1px solid black;border-top:none;}} |
| 1372 |
>>> |
| 1373 |
|
| 1374 |
This should show the first hline in table if Array is loaded. |
| 1375 |
|
| 1376 |
\<fix first tabular hline\><<< |
| 1377 |
\Css{.hline:first-child{border-bottom:1px solid black;border-top:none;}} |
| 1378 |
>>> |
| 1379 |
|
| 1380 |
\<td save EndP\><<< |
| 1381 |
\SaveEndP |
| 1382 |
>>> |
| 1383 |
|
| 1384 |
\<td recall EndP\><<< |
| 1385 |
\RecallEndP |
| 1386 |
>>> |
| 1387 |
|
| 1388 |
|
| 1389 |
\<mml hline\><<< |
| 1390 |
<\a:mathml mtd \mml:class="hline-mtd"></\a:mathml mtd> |
| 1391 |
>>> |
| 1392 |
|
| 1393 |
|
| 1394 |
|
| 1395 |
|
| 1396 |
\<mathml latex\><<< |
| 1397 |
|<mathml fonts|> |
| 1398 |
\let\A:fbox=\a:fbox |
| 1399 |
\let\B:fbox=\b:fbox |
| 1400 |
\let\OLDn:fbox:\n:fbox: |
| 1401 |
\def\OLDf:box{\ifx \EndPicture \:UnDef |
| 1402 |
\expandafter \OLDn:fbox: \else\expandafter \o:fbox: \fi} |
| 1403 |
\def\:temp{\relax\ifmmode |
| 1404 |
\Configure{fbox}{\leavevmode\Configure{HtmlPar}{}{}{}{}\IgnoreRule |
| 1405 |
\AA:text{fbox}}{\BB:text\EndIgnoreRule}\else |
| 1406 |
\Configure{fbox}{\IgnoreRule\A:fbox}{\B:fbox\EndIgnoreRule}\fi |
| 1407 |
\OLDf:box} |
| 1408 |
\HLet\fbox\:temp |
| 1409 |
\let\A:mbox|=\a:mbox |
| 1410 |
\let\B:mbox|=\b:mbox |
| 1411 |
\let\OLD:mbox|=\mbox |
| 1412 |
\def\mbox{\relax\ifmmode \Configure{mbox}{\AA:text{mbox}}{\BB:text}\else |
| 1413 |
\Configure{mbox}{\A:mbox}{\B:mbox}\fi\OLD:mbox} |
| 1414 |
|<mathml text util|> |
| 1415 |
>>> |
| 1416 |
|
| 1417 |
|
| 1418 |
\<mathml text util\><<< |
| 1419 |
\NewConfigure{@mtext}{1} |
| 1420 |
\Configure{@mtext}{ } |
| 1421 |
\def\AA:text#1{|<config start mtext|>} |
| 1422 |
\def\BB:text{|<config end mtext|>} |
| 1423 |
>>> |
| 1424 |
|
| 1425 |
|
| 1426 |
\<config start mtext\><<< |
| 1427 |
\mtexttrue |
| 1428 |
\HCode{<\a:mathml mstyle\Hnewline \mml:class="#1"><\a:mathml |
| 1429 |
mtext \a:@mtext>}|<start mtext space|>\PauseMathClass |
| 1430 |
\ifmmode\else |
| 1431 |
|<config math within mtext|>% |
| 1432 |
\fi |
| 1433 |
>>> |
| 1434 |
|
| 1435 |
|
| 1436 |
\<config end mtext\><<< |
| 1437 |
\mtextfalse\EndPauseMathClass|<end mtext space|>\HCode |
| 1438 |
{</\a:mathml mtext></\a:mathml mstyle>}% |
| 1439 |
>>> |
| 1440 |
|
| 1441 |
\<config math within mtext\><<< |
| 1442 |
\Configure{$}% |
| 1443 |
{\EndPauseMathClass \mtextfalse |
| 1444 |
|<end mtext space|>\HCode{</\a:mathml mtext><\a:mathml |
| 1445 |
mstyle\Hnewline \mml:class="math">}}% |
| 1446 |
{\HCode{</\a:mathml mstyle><\a:mathml |
| 1447 |
mtext \a:@mtext>}|<start mtext space|>\PauseMathClass |
| 1448 |
\mtexttrue}% |
| 1449 |
{}% |
| 1450 |
>>> |
| 1451 |
|
| 1452 |
\<config math within mtext\><<< |
| 1453 |
\Configure{()}% |
| 1454 |
{\EndPauseMathClass \mtextfalse |
| 1455 |
|<end mtext space|>\HCode{</\a:mathml mtext><\a:mathml |
| 1456 |
mstyle\Hnewline \mml:class="math">}$}% |
| 1457 |
{$\HCode{</\a:mathml mstyle><\a:mathml |
| 1458 |
mtext \a:@mtext>}|<start mtext space|>\PauseMathClass |
| 1459 |
\mtexttrue}% |
| 1460 |
{}% |
| 1461 |
>>> |
| 1462 |
|
| 1463 |
|
| 1464 |
|
| 1465 |
% \Configure{$} |
| 1466 |
% {\Configure{@math}{|<inline display|>}\DviMath} |
| 1467 |
% {\EndDviMath}{} |
| 1468 |
% |
| 1469 |
% \Configure{()} |
| 1470 |
% {\Configure{@math}{|<inline display|>}\csname a:mathml()\endcsname |
| 1471 |
% \DviMath |
| 1472 |
% \Tg<\a:mathml mrow\Hnewline>$} |
| 1473 |
% {$\Tg</\a:mathml mrow>% |
| 1474 |
% \EndDviMath\csname b:mathml()\endcsname} |
| 1475 |
|
| 1476 |
|
| 1477 |
|
| 1478 |
\begin{verbatim} |
| 1479 |
\documentclass{article} |
| 1480 |
\begin{document} |
| 1481 |
$ \mbox{is right-continuous at } -r $ |
| 1482 |
\end{document} |
| 1483 |
|
| 1484 |
I see the problematic space between |
| 1485 |
|
| 1486 |
is right-continuous at |
| 1487 |
|
| 1488 |
and |
| 1489 |
|
| 1490 |
-r |
| 1491 |
|
| 1492 |
but I don't understand it. The mathml code currently has there |
| 1493 |
|
| 1494 |
<\a:mathml mrow><\a:mathml mtext>is right-continuous at</\a:mathml mtext></\a:mathml mrow> |
| 1495 |
<\a:mathml mo>−</\a:mathml mo><\a:mathml mi>r</\a:mathml mi> |
| 1496 |
|
| 1497 |
Replacing mrow with mstyle doesn't make a difference. Removing |
| 1498 |
the mrow solves the problem of the extra space. |
| 1499 |
|
| 1500 |
I introduced the above changes to the mathml and mozilla-mathml |
| 1501 |
configurations, respectively. |
| 1502 |
\end{verbatim} |
| 1503 |
|
| 1504 |
|
| 1505 |
|
| 1506 |
|
| 1507 |
|
| 1508 |
\<amstex.tex mathml\><<< |
| 1509 |
|<mathml text util|> |
| 1510 |
\Configure{text}{\AA:text{text}}{\BB:text} |
| 1511 |
\Configure{format} |
| 1512 |
{\HCode{<\a:mathml mtable \mml:class="format">}} |
| 1513 |
{\HCode{</\a:mathml mtable>}} |
| 1514 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="format">}} |
| 1515 |
{\HCode{</\a:mathml mtr>}} |
| 1516 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="format">}} |
| 1517 |
{\HCode{</\a:mathml mtd>}} |
| 1518 |
>>> |
| 1519 |
|
| 1520 |
|
| 1521 |
|
| 1522 |
\<amsmath mathml\><<< |
| 1523 |
\Configure{above} |
| 1524 |
{\Send{GROUP}{0}{<\a:mathml mfrac |
| 1525 |
linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1526 |
\HCode{</\a:mathml mrow>}\o:@@over:\:gobbleII} |
| 1527 |
{\HCode{<\a:mathml |
| 1528 |
mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>}} |
| 1529 |
\def\overwithdelims:III#1#2#3{% |
| 1530 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1531 |
\Send{GROUP}{0}{<\a:mathml mfrac linethickness="0"><\a:mathml mrow>}% |
| 1532 |
\HCode{</\a:mathml mrow>}\o:over: |
| 1533 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1534 |
\else |
| 1535 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1536 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac |
| 1537 |
\a:mathml linethickness="0"><\a:mathml mrow>}% |
| 1538 |
\HCode{</\a:mathml mrow>}\o:@@over: |
| 1539 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1540 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1541 |
\fi |
| 1542 |
} |
| 1543 |
>>> |
| 1544 |
|
| 1545 |
|
| 1546 |
\<configure mathml tex4ht\><<< |
| 1547 |
\Configure{over} |
| 1548 |
{\Send{GROUP}{0} |
| 1549 |
{<\a:mathml mfrac><\a:mathml mrow>}\HCode{</\a:mathml mrow>}} |
| 1550 |
{\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0} |
| 1551 |
{</\a:mathml mrow></\a:mathml mfrac>}} |
| 1552 |
\Configure{atop} |
| 1553 |
{\Send{GROUP}{0}{<\a:mathml mfrac linethickness="0"><\a:mathml mrow>}\HCode{</\a:mathml mrow>}} |
| 1554 |
{\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>}} |
| 1555 |
\Configure{above} |
| 1556 |
{\Send{GROUP}{0}{<\a:mathml mfrac linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1557 |
\HCode{</\a:mathml mrow>}\o:over:\:gobbleII} |
| 1558 |
{\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>}} |
| 1559 |
>>> |
| 1560 |
|
| 1561 |
\<configure mathml tex4ht\><<< |
| 1562 |
\Configure{abovewithdelims} |
| 1563 |
{\abovewithdelims:III} |
| 1564 |
{} |
| 1565 |
\def\abovewithdelims:III#1#2#3{% |
| 1566 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1567 |
\Send{GROUP}{0}{<\a:mathml mfrac linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1568 |
\HCode{</\a:mathml mrow>}\o:over: |
| 1569 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1570 |
\else |
| 1571 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1572 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac |
| 1573 |
\a:mathml linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1574 |
\HCode{</\a:mathml mrow>}\o:over: |
| 1575 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1576 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1577 |
\fi |
| 1578 |
\tmp:dim |
| 1579 |
} |
| 1580 |
\Configure{atopwithdelims} |
| 1581 |
{\atopwithdelims:III} |
| 1582 |
{} |
| 1583 |
\def\atopwithdelims:III#1#2#3{% |
| 1584 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1585 |
\Send{GROUP}{0}{<\a:mathml mfrac linethickness="0"><\a:mathml mrow>}% |
| 1586 |
\HCode{</\a:mathml mrow>}\o:atop: |
| 1587 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1588 |
\else |
| 1589 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1590 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac |
| 1591 |
\a:mathml linethickness="0"><\a:mathml mrow>}% |
| 1592 |
\HCode{</\a:mathml mrow>}\o:atop: |
| 1593 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1594 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1595 |
\fi |
| 1596 |
} |
| 1597 |
\Configure{overwithdelims} |
| 1598 |
{\overwithdelims:III} |
| 1599 |
{} |
| 1600 |
\def\overwithdelims:III#1#2#3{% |
| 1601 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1602 |
\Send{GROUP}{0}{<\a:mathml mfrac><\a:mathml mrow>}% |
| 1603 |
\HCode{</\a:mathml mrow>}\o:over: |
| 1604 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1605 |
\else |
| 1606 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1607 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac><\a:mathml mrow>}% |
| 1608 |
\HCode{</\a:mathml mrow>}\o:over: |
| 1609 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1610 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1611 |
\fi |
| 1612 |
} |
| 1613 |
>>> |
| 1614 |
|
| 1615 |
|
| 1616 |
|
| 1617 |
\<configure mathml amsmath\><<< |
| 1618 |
\Configure{abovewithdelims} |
| 1619 |
{\abovewithdelims:III} |
| 1620 |
{} |
| 1621 |
\def\abovewithdelims:III#1#2#3{% |
| 1622 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1623 |
\Send{GROUP}{0}{<\a:mathml mfrac linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1624 |
\HCode{</\a:mathml mrow>}\o:@@over: |
| 1625 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1626 |
\else |
| 1627 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1628 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac |
| 1629 |
\a:mathml linethickness="\the\tmp:dim"><\a:mathml mrow>}% |
| 1630 |
\HCode{</\a:mathml mrow>}\o:@@over: |
| 1631 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1632 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1633 |
\fi |
| 1634 |
\tmp:dim |
| 1635 |
} |
| 1636 |
\Configure{atopwithdelims} |
| 1637 |
{\atopwithdelims:III} |
| 1638 |
{} |
| 1639 |
\def\atopwithdelims:III#1#2#3{% |
| 1640 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1641 |
\Send{GROUP}{0}{<\a:mathml mfrac \a:mathml linethickness="0"><\a:mathml mrow>}% |
| 1642 |
\HCode{</\a:mathml mrow>}\o:@@atop: |
| 1643 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1644 |
\else |
| 1645 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1646 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac |
| 1647 |
\a:mathml linethickness="0"><\a:mathml mrow>}% |
| 1648 |
\HCode{</\a:mathml mrow>}\o:@@atop: |
| 1649 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1650 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1651 |
\fi |
| 1652 |
} |
| 1653 |
\Configure{overwithdelims} |
| 1654 |
{\overwithdelims:III} |
| 1655 |
{} |
| 1656 |
\def\overwithdelims:III#1#2#3{% |
| 1657 |
\def\:temp{#2#3}\def\:tempa{..}\ifx \:temp\:tempa |
| 1658 |
\Send{GROUP}{0}{<\a:mathml mfrac><\a:mathml mrow>}% |
| 1659 |
\HCode{</\a:mathml mrow>}\o:@@over: |
| 1660 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>} |
| 1661 |
\else |
| 1662 |
\Send{GROUP}{0}{<\a:mathml mfenced \a:mathml separators=""\Hnewline |
| 1663 |
\a:mathml open="|<lr del 2|>" \a:mathml close="|<lr del 3|>"><\a:mathml mfrac><\a:mathml mrow>}% |
| 1664 |
\HCode{</\a:mathml mrow>}\o:@@over: |
| 1665 |
\HCode{<\a:mathml mrow>}\Send{EndGROUP}{0}{</\a:mathml |
| 1666 |
mrow></\a:mathml mfrac></\a:mathml mfenced>} |
| 1667 |
\fi |
| 1668 |
} |
| 1669 |
>>> |
| 1670 |
|
| 1671 |
Use correct math style for Amsmath's variants of inline fractions. We also need to add fractions markup in tfrac and dfrac to |
| 1672 |
support their use \Link[https://github.com/michal-h21/make4ht/issues/129]{}{}inside of fractions\EndLink. |
| 1673 |
|
| 1674 |
\<configure mathml amsmath\><<< |
| 1675 |
\pend:def\dfrac{\Configure{genfrac}{\HCode{<\a:mathml mstyle \a:mathml displaystyle="true"><mfrac><mrow>} |
| 1676 |
\Configure{over}{}{}}{}{}{\HCode{</mrow><mrow>} |
| 1677 |
} {}{\HCode{</mrow></mfrac></\a:mathml mstyle>}}} |
| 1678 |
\pend:def\tfrac{\Configure{genfrac}{\HCode{<\a:mathml mstyle \a:mathml displaystyle="false"><mfrac><mrow>} |
| 1679 |
\Configure{over}{}{}}{}{}{\HCode{</mrow><mrow>} |
| 1680 |
}{}{\HCode{</mrow></mfrac></\a:mathml mstyle>}}} |
| 1681 |
\pend:def\dbinom{\Configure{genfrac}{\HCode{<\a:mathml mstyle \a:mathml displaystyle="true">}}{}{}{}{}{\HCode{</\a:mathml mstyle>}}} |
| 1682 |
\pend:def\tbinom{\Configure{genfrac}{\HCode{<\a:mathml mstyle \a:mathml displaystyle="false">}}{}{}{}{}{\HCode{</\a:mathml mstyle>}}} |
| 1683 |
>>> |
| 1684 |
|
| 1685 |
\<mathml latex\><<< |
| 1686 |
\Configure{frac} |
| 1687 |
{\Tg<\a:mathml mfrac>\Tg<\a:mathml mrow\Hnewline>} |
| 1688 |
{\Tg</\a:mathml mrow>\Configure{over}{}{}} |
| 1689 |
{\Tg<\a:mathml mrow\Hnewline>} |
| 1690 |
{\Tg</\a:mathml mrow>\Tg</\a:mathml mfrac>} |
| 1691 |
>>> |
| 1692 |
|
| 1693 |
|
| 1694 |
|
| 1695 |
\<configure html-mml amsmath\><<< |
| 1696 |
\ifx \mathdisplay@@pop\:UnDef |
| 1697 |
\ifx \emdf@La\:UnDef |
| 1698 |
|<amsmath html-mml pre 2000|> |
| 1699 |
\else |
| 1700 |
|<amsmath html-mml jan 2000|> |
| 1701 |
\fi |
| 1702 |
\else |
| 1703 |
|<amsmath html-mml july 2000|> |
| 1704 |
\fi |
| 1705 |
>>> |
| 1706 |
|
| 1707 |
|
| 1708 |
% \Configure{quad}{{\ifmathml \ifmtext \o:quad:\else |
| 1709 |
% \fi\else \o:quad: \fi}} |
| 1710 |
% |
| 1711 |
|
| 1712 |
\<amsmath mathml\><<< |
| 1713 |
\Configure{tmspace} |
| 1714 |
{\ifdim \textspace>0.2em |
| 1715 |
\HCode{<\a:mathml mspace |
| 1716 |
width="\textspace" \mml:class="tmspace"/>}% |
| 1717 |
\else \HCode{<\a:mathml mspace |
| 1718 |
width="0.3em" \mml:class="thinspace"/>}\fi |
| 1719 |
} |
| 1720 |
>>> |
| 1721 |
|
| 1722 |
|
| 1723 |
Use variant of original LaTeX macro used in \textunderscore |
| 1724 |
\<configure mathml tex4ht\><<< |
| 1725 |
\def\mathunderscore{\nfss@text{\HChar{95}}} |
| 1726 |
>>> |
| 1727 |
|
| 1728 |
|
| 1729 |
\<try inline par\><<< |
| 1730 |
\ShowPar\par{\HCondtrue\noindent}% |
| 1731 |
>>> |
| 1732 |
|
| 1733 |
|
| 1734 |
% \Configure{math}{} |
| 1735 |
|
| 1736 |
|
| 1737 |
% this used to be in \providemtextclass. Why? It produces totally invalid |
| 1738 |
% MathML. Where is </mtext> opened? |
| 1739 |
% \HCode{</mtext>}\ht:special{t4ht@,}\HCode{<mtext \a:@mtext>}\ht:special{t4ht@,&\#x00A0;}% |
| 1740 |
\<mathml fonts\><<< |
| 1741 |
|
| 1742 |
\def\providemtextclass#1{% |
| 1743 |
\Configure{@mtext}{#1}% |
| 1744 |
} |
| 1745 |
|
| 1746 |
\Configure{texttt} |
| 1747 |
{\ifmathml \providemtextclass{\mml:class="texttt" |
| 1748 |
mathvariant="monospace" }\fi} |
| 1749 |
{}% |
| 1750 |
\Configure{textit} |
| 1751 |
{\ifmathml \providemtextclass{\mml:class="textit" |
| 1752 |
mathvariant="italic" }\fi} |
| 1753 |
{}% |
| 1754 |
\Configure{textrm} |
| 1755 |
{\ifmathml \providemtextclass{\mml:class="textrm" |
| 1756 |
mathvariant="normal" }\fi} |
| 1757 |
{}% |
| 1758 |
\Configure{textup} |
| 1759 |
{\ifmathml \providemtextclass{\mml:class="textup" |
| 1760 |
mathvariant="normal" }\fi} |
| 1761 |
{}% |
| 1762 |
\Configure{textsl} |
| 1763 |
{\ifmathml \providemtextclass{\mml:class="textsl" |
| 1764 |
mathvariant="italic" }\fi} |
| 1765 |
{}% |
| 1766 |
\Configure{textsf} |
| 1767 |
{\ifmathml \providemtextclass{\mml:class="textsf" |
| 1768 |
mathvariant="sans-serif" }\fi} |
| 1769 |
{}% |
| 1770 |
\Configure{textbf} |
| 1771 |
{\ifmathml \providemtextclass{\mml:class="textbf" |
| 1772 |
mathvariant="bold" }\fi} |
| 1773 |
{}% |
| 1774 |
\Configure{textsc} |
| 1775 |
{\ifmathml \providemtextclass{\mml:class="textsc" |
| 1776 |
mathvariant="normal" }\fi} |
| 1777 |
{}% |
| 1778 |
\Configure{emph} |
| 1779 |
{\ifmathml \providemtextclass{\mml:class="emph" |
| 1780 |
mathvariant="italic" }\fi} |
| 1781 |
{}% |
| 1782 |
>>> |
| 1783 |
|
| 1784 |
The bf command should work in math. The following definition is a bit fragile, it expects |
| 1785 |
that it is used inside a group for a small chunk of text. |
| 1786 |
|
| 1787 |
\<mathml fonts\><<< |
| 1788 |
\def\:closebf{\HCode{</\a:mathml mi>}\EndPauseMathClass} |
| 1789 |
\def\:tempa{\ifmmode\expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi{\PauseMathClass\HCode{<\a:mathml mi mathvariant="bold">}\aftergroup\:closebf}{\o:bf:}} |
| 1790 |
\HLet\bf\:tempa |
| 1791 |
>>> |
| 1792 |
|
| 1793 |
|
| 1794 |
\<configure html-mml latex\><<< |
| 1795 |
\:CheckOption{fonts} \if:Option |
| 1796 |
\Configure{texttt} |
| 1797 |
{\ifmathml \providemtextclass{\mml:class="texttt" |
| 1798 |
mathvariant="monospace" }% |
| 1799 |
\else \HCode{<span class="texttt">}\NoFonts\fi} |
| 1800 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1801 |
\Configure{textit} |
| 1802 |
{\ifmathml \providemtextclass{\mml:class="textit" |
| 1803 |
mathvariant="italic" }% |
| 1804 |
\else \HCode{<span class="textit">}\NoFonts\fi} |
| 1805 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1806 |
\Configure{textrm} |
| 1807 |
{\ifmathml \providemtextclass{ \mml:class="textrm" |
| 1808 |
mathvariant="normal" }% |
| 1809 |
\else \HCode{<span class="textrm">}\NoFonts\fi} |
| 1810 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1811 |
\Configure{textup} |
| 1812 |
{\ifmathml \providemtextclass{ \mml:class="textup" |
| 1813 |
mathvariant="normal" }% |
| 1814 |
\else \HCode{<span class="textup">}\NoFonts\fi} |
| 1815 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1816 |
\Configure{textsl} |
| 1817 |
{\ifmathml \providemtextclass{ \mml:class="textst" |
| 1818 |
mathvariant="italic" }% |
| 1819 |
\else \HCode{<span class="textsl">}\NoFonts\fi} |
| 1820 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1821 |
\Configure{textsf} |
| 1822 |
{\ifmathml \providemtextclass{ \mml:class="textsf" |
| 1823 |
mathvariant="sans-serif" }% |
| 1824 |
\else \HCode{<span class="textsf">}\NoFonts\fi} |
| 1825 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1826 |
\Configure{textbf} |
| 1827 |
{\ifmathml \providemtextclass{ \mml:class="textbf" |
| 1828 |
mathvariant="bold" }% |
| 1829 |
\else \HCode{<span class="textbf">}\NoFonts\fi} |
| 1830 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1831 |
\Configure{textsc} |
| 1832 |
{\ifmathml \providemtextclass{ \mml:class="textsc" |
| 1833 |
mathvariant="normal" }% |
| 1834 |
\else \HCode{<span class="textsc">}\NoFonts\fi} |
| 1835 |
{\ifmathml\else \EndNoFonts\HCode{</span>}\fi} |
| 1836 |
\Configure{emph} |
| 1837 |
{\ifmathml \providemtextclass{ \mml:class="emph" |
| 1838 |
mathvariant="italic" }% |
| 1839 |
\else \HCode{<span class="emph">}\NoFonts\fi} |
| 1840 |
{\ifmathml\else\EndNoFonts \HCode{</span>}\fi} |
| 1841 |
\fi |
| 1842 |
>>> |
| 1843 |
|
| 1844 |
The \verb+\bgroup...\egroup+ is to handle cases like |
| 1845 |
\verb+\nathbf{a}^x+. |
| 1846 |
|
| 1847 |
|
| 1848 |
\<configure mathml fontmath\><<< |
| 1849 |
\def\bold:version{bold} |
| 1850 |
\Configure{mathbf}% |
| 1851 |
{\bgroup\Tg<\a:mathml mstyle |
| 1852 |
mathvariant="bold">}% |
| 1853 |
{\Tg</\a:mathml mstyle>\egroup}% |
| 1854 |
\Configure{mathit}% |
| 1855 |
{\bgroup\Tg<\a:mathml mstyle mathvariant="\ifx |
| 1856 |
\bold:version\math@version bold-\fi italic">}% |
| 1857 |
{\Tg</\a:mathml mstyle>\egroup}% |
| 1858 |
\Configure{mathrm}% |
| 1859 |
{\bgroup\Tg<\a:mathml mstyle |
| 1860 |
mathvariant="\ifx |
| 1861 |
\bold:version\math@version bold\else normal\fi">}% |
| 1862 |
{\Tg</\a:mathml mstyle>\egroup}% |
| 1863 |
\Configure{mathsf}% |
| 1864 |
{\bgroup\Tg<\a:mathml mstyle mathvariant="\ifx |
| 1865 |
\bold:version\math@version bold-\fi sans-serif">}% |
| 1866 |
{\Tg</\a:mathml mstyle>\egroup}% |
| 1867 |
\Configure{mathtt}% |
| 1868 |
{\bgroup\Tg<\a:mathml mstyle mathvariant="monospace">}% |
| 1869 |
{\Tg</\a:mathml mstyle>\egroup}% |
| 1870 |
>>> |
| 1871 |
|
| 1872 |
\<configure mathml fontmath\><<< |
| 1873 |
\Css{ |
| 1874 |
math mstyle[mathvariant="bold"] { |
| 1875 |
font-weight: bold; |
| 1876 |
font-style: normal; |
| 1877 |
} |
| 1878 |
} |
| 1879 |
\Css{ |
| 1880 |
math mstyle[mathvariant="normal"] { |
| 1881 |
font-weight: normal; |
| 1882 |
font-style: normal; |
| 1883 |
} |
| 1884 |
} |
| 1885 |
>>> |
| 1886 |
|
| 1887 |
\<configure mathml amsfonts\><<< |
| 1888 |
\Configure{mathbb}{}{} |
| 1889 |
\Configure{mathfrak}{}{} |
| 1890 |
>>> |
| 1891 |
|
| 1892 |
|
| 1893 |
|
| 1894 |
Used to be |
| 1895 |
|
| 1896 |
\begin{verbatim} |
| 1897 |
\Configure{mathrm}{\Tg<\a:mathml mi \mml:class="mathrm">\PauseMathClass}% |
| 1898 |
{\EndPauseMathClass\Tg</\a:mathml mi>}% |
| 1899 |
\Configure{mathbf}{\Tg<\a:mathml mi \mml:class="mathbf" |
| 1900 |
mathvariant="bold">\PauseMathClass}% |
| 1901 |
{\EndPauseMathClass\Tg</\a:mathml mi>}% |
| 1902 |
\end{verbatim} |
| 1903 |
|
| 1904 |
|
| 1905 |
\<configure html-mml latex\><<< |
| 1906 |
\Css{math .texttt { font-family: monospace; }} |
| 1907 |
\Css{math .textit { font-style: italic; }} |
| 1908 |
\Css{math .textsl { font-style: oblique; }} |
| 1909 |
\Css{math .textsf { font-family: sans-serif; }} |
| 1910 |
\Css{math .textbf { font-weight: bold; }} |
| 1911 |
>>> |
| 1912 |
|
| 1913 |
|
| 1914 |
|
| 1915 |
Support for the \verb'\mathversion' command. Thanks to Linas Stonys |
| 1916 |
for the report and additional testing. |
| 1917 |
|
| 1918 |
\<configure mathml fontmath\><<< |
| 1919 |
|<mathversion config|> |
| 1920 |
>>> |
| 1921 |
|
| 1922 |
We can configure attributes that will be added to the \verb'<math>' element |
| 1923 |
using \verb'\Configure{mathversion-style}' ideally, |
| 1924 |
use something like \verb'mathvariant="xxx"'. |
| 1925 |
|
| 1926 |
\<mathversion config\><<< |
| 1927 |
\NewConfigure{mathversion-style}[2]{\expandafter\gdef\csname :mathversion-#1\endcsname{#2}} |
| 1928 |
% ToDo: Add support for other mathversions |
| 1929 |
\Configure{mathversion-style}{bold}{\a:mathml mathvariant="bold-italic"} |
| 1930 |
>>> |
| 1931 |
|
| 1932 |
Now we can append code to \verb'\mathversion'. |
| 1933 |
It will add the mathvariant tag to the \verb'<math>' element. |
| 1934 |
|
| 1935 |
\<mathversion config\><<< |
| 1936 |
\append:defI\mathversion{% |
| 1937 |
% \a:DviMathML is executed at the beginning of math \a:@math is hook for attributes. we need to append out tags to it |
| 1938 |
\Configure{DviMathML}{\append:def\a:@math{\ifcsname :mathversion-\math@version\endcsname\expandafter\csname :mathversion-\math@version\endcsname\fi}}{}% |
| 1939 |
} |
| 1940 |
>>> |
| 1941 |
|
| 1942 |
\<plain,latex mathml\><<< |
| 1943 |
\Configure{afterSUB}{'}{\def\SUB:prime{\SUB:SUP}} |
| 1944 |
\Configure{'} |
| 1945 |
{\let\:primes=\empty} |
| 1946 |
{\relax \csname SUB:prime\endcsname\sp{% |
| 1947 |
\global\let\SUB:prime=\:UnDef |
| 1948 |
\def\:tempa{\prime\prime}\ifx \:tempa\:primes |
| 1949 |
\mathop{\HCode{<\a:mathml mi>\string&\#x2033;</\a:mathml mi>}}\else |
| 1950 |
\def\:tempa{\prime\prime\prime}\ifx \:tempa\:primes |
| 1951 |
\mathop{\HCode{<\a:mathml mi>\string&\#x2034;</\a:mathml mi>}}\else |
| 1952 |
\:primes \fi\fi}% |
| 1953 |
} |
| 1954 |
{\let\prime=\relax \xdef\:primes{\:primes\prime}} |
| 1955 |
>>> |
| 1956 |
|
| 1957 |
LaTeX places the primes within superscript, and mathml seems to follow |
| 1958 |
suit (maybe because of the use of latex fonts in mozilla). However, |
| 1959 |
unicode maps already seem to assume raised representation for the |
| 1960 |
primes. |
| 1961 |
|
| 1962 |
|
| 1963 |
\<configure html-mml latex\><<< |
| 1964 |
\:CheckOption{mathjax}\if:Option |
| 1965 |
\Configure{MathjaxSource}{https://cdn.jsdelivr.net/npm/mathjax@3/es5/mml-chtml.js} |
| 1966 |
\Configure{@HEAD}{\HCode{ <script type="text/javascript" id="MathJax-script" async="async" src="\a:MathjaxSource"></script> \Hnewline}} |
| 1967 |
\fi |
| 1968 |
>>> |
| 1969 |
|
| 1970 |
|
| 1971 |
We may want to include LaTeX source as an annotation in MathML. In particular LaTeX PDF tagging code can use |
| 1972 |
this feature. We will not use it by default, but only with texsource option, as it can potentially |
| 1973 |
break some functionality. |
| 1974 |
|
| 1975 |
The code is based on the LaTeX MathJax code, but heavily modified. |
| 1976 |
|
| 1977 |
\<configure html-mml latex\><<< |
| 1978 |
\:CheckOption{texsource}\if:Option |
| 1979 |
|
| 1980 |
\newtoks\mmleqtoks |
| 1981 |
\ExplSyntaxOn |
| 1982 |
\cs_new_protected:Npn \mmlalteqtoks #1 |
| 1983 |
{ |
| 1984 |
% save tokens, but preserve spaces |
| 1985 |
% https://tex.stackexchange.com/a/44444/2891 |
| 1986 |
\tl_set:Nn \l_tmpa_tl {#1} |
| 1987 |
\regex_replace_all:nnN { . } { \c{string} \0 } \l_tmpa_tl |
| 1988 |
\tl_set:Nx \l_tmpa_tl { \l_tmpa_tl } |
| 1989 |
% % replace < > and & with xml entities |
| 1990 |
\regex_replace_all:nnN { \x{26} } { & } \l_tmpa_tl |
| 1991 |
\regex_replace_all:nnN { \x{3C} } { < } \l_tmpa_tl |
| 1992 |
\regex_replace_all:nnN { \x{3E} } { > } \l_tmpa_tl |
| 1993 |
% \regex_replace_all:nnN { \n } {\HCode{ \Hnewline }} \l_tmpa_tl |
| 1994 |
% replace \par command with blank lines |
| 1995 |
\regex_replace_all:nnN { \x{5C}par\b } {\x{A}\x{A}} \l_tmpa_tl |
| 1996 |
\tl_set:Nx \mmleqtoks{ \l_tmpa_tl } |
| 1997 |
|
| 1998 |
%\HCode{\l_tmpb_tl} |
| 1999 |
} |
| 2000 |
\ExplSyntaxOff |
| 2001 |
|
| 2002 |
|
| 2003 |
\def\AltMath#1${\mmlalteqtoks{#1}% |
| 2004 |
#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$} |
| 2005 |
\Configure{$}{\Configure{@math}{display="inline"}\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}}{\HCode{</\a:mathml semantics>}\EndDviMath}{\expandafter\AltMath} |
| 2006 |
|
| 2007 |
\def\AltMathParen#1\){\mmlalteqtoks{#1}% |
| 2008 |
#1\HCode{</\a:mathml mrow><a\a:mathml nnotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$} |
| 2009 |
|
| 2010 |
\def\AltMathParen#1\){\mmlalteqtoks{#1}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}\)} |
| 2011 |
%\Configure{()}{\Configure{@math}{display="inline"}\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}\AltMathParen$}{\EndDviMath\HCode{</\a:mathml semantics>}} |
| 2012 |
\Configure{()} |
| 2013 |
{\Configure{@math}{%\a:mathml |
| 2014 |
display="inline" |
| 2015 |
}\csname a:mathml()\endcsname |
| 2016 |
\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}$\expandafter\AltMathParen} |
| 2017 |
{$\HCode{</\a:mathml semantics>}\EndDviMath\csname b:mathml()\endcsname} |
| 2018 |
|
| 2019 |
|
| 2020 |
\long\def\AltDisplay#1\]{\mmlalteqtoks{#1}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation></\a:mathml semantics>}\]} |
| 2021 |
\Configure{[]}{\Configure{@math}{display="block"}\DviMath$$\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow>}\AltDisplay}{$$\EndDviMath} |
| 2022 |
|
| 2023 |
|
| 2024 |
% \long\def\MMLAltlDisplayDollars#1$${\mmlalteqtoks{#1}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation>}$$} |
| 2025 |
|
| 2026 |
% configuration of display math doesn't work yet. I need to investigate it. |
| 2027 |
% \Configure{$$} |
| 2028 |
% {\Configure{@math}{%\a:mathml |
| 2029 |
% display="block" |
| 2030 |
% }\IgnorePar |
| 2031 |
% \ifvmode\else \HCode{<!--tex4ht:inline-->}\fi |
| 2032 |
% \EndP\DviMath\HCode{<\a:mathml semantics><\a:mathml mrow>}} |
| 2033 |
% {\HCode{</\a:mathml semantics>}\EndDviMath\ShowPar\par{\csname HCondtrue\endcsname\noindent}} |
| 2034 |
% {\DisplayMathtrue\expandafter\MMLAltlDisplayDollars} |
| 2035 |
|
| 2036 |
|
| 2037 |
% \renewcommand\eqannotate[1]{\mmlalteqtoks{#1}\HCode{<\a:mathml semantics><\a:mathml mrow>}#1\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">\mmleqtoks</\a:mathml annotation></\a:mathml semantics>}} |
| 2038 |
|
| 2039 |
|
| 2040 |
% environment support |
| 2041 |
\newcommand\MMLVerbMathToks[2]{% |
| 2042 |
\ifmmode% |
| 2043 |
\begin{old#2}% |
| 2044 |
#1% |
| 2045 |
\end{old#2}% |
| 2046 |
\else% |
| 2047 |
\mmlalteqtoks{\begin{#2} |
| 2048 |
#1 |
| 2049 |
\end{#2}}% |
| 2050 |
\begingroup% |
| 2051 |
\ifvmode\IgnorePar\fi\EndP\Configure{@math}{display="block"}\DviMath\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow>} |
| 2052 |
\Configure{$$}{}{}{} |
| 2053 |
\begin{old#2} |
| 2054 |
#1 |
| 2055 |
\end{old#2} |
| 2056 |
\HCode{</\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">} |
| 2057 |
\HCode{\mmleqtoks} |
| 2058 |
\HCode{</\a:mathml annotation></\a:mathml semantics>} |
| 2059 |
\EndDviMath |
| 2060 |
\endgroup |
| 2061 |
\fi |
| 2062 |
} |
| 2063 |
|
| 2064 |
% we must handle equations separatelly. |
| 2065 |
% it is a bit messy |
| 2066 |
\newcommand\MMLVerbMathToksEquation[2]{% |
| 2067 |
\mmlalteqtoks{\begin{#2} |
| 2068 |
#1 |
| 2069 |
\end{#2}}% |
| 2070 |
\begingroup% |
| 2071 |
\def\mlabeledtr{mtr} |
| 2072 |
\def\swapmlabeledtr##1##2{##2\HCode{</\a:mathml mtd><\a:mathml mtd>}##1}% |
| 2073 |
\ifOption{mathjax}{% |
| 2074 |
% the mlabeledtr element expects the equation number as the first child. This element is supported only by MathJax, |
| 2075 |
% so we use normal mtr if we don't use the MathJax renderer. In that case, the equationnumber should be second |
| 2076 |
\def\mlabeledtr{mlabeledtr} % this element can be used to print the equation number, but it is supported only by MathJax% |
| 2077 |
\def\swapmlabeledtr##1##2{##1\HCode{</\a:mathml mtd><\a:mathml mtd>}##2}% |
| 2078 |
}{}% |
| 2079 |
\ifvmode\IgnorePar\fi\EndP\Configure{@math}{display="block"}\DviMath\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow><\a:mathml mtable><\a:mathml \mlabeledtr><\a:mathml mtd>}% |
| 2080 |
\refstepcounter{equation}% |
| 2081 |
\swapmlabeledtr{\hbox{\@eqnnum}}{#1}% |
| 2082 |
\HCode{</\a:mathml mtd> |
| 2083 |
</\a:mathml \mlabeledtr></\a:mathml mtable></\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">}% |
| 2084 |
\HCode{\mmleqtoks}% |
| 2085 |
\HCode{</\a:mathml annotation></\a:mathml semantics>}% |
| 2086 |
\EndDviMath% |
| 2087 |
\endgroup% |
| 2088 |
} |
| 2089 |
|
| 2090 |
\ExplSyntaxOn |
| 2091 |
\newcommand\MMLVerbMath[1]{% |
| 2092 |
\cs_if_exist:cTF{#1}{ |
| 2093 |
\expandafter\let\csname old#1\expandafter\endcsname\csname #1\endcsname |
| 2094 |
\expandafter\let\csname endold#1\expandafter\endcsname\csname end#1\endcsname |
| 2095 |
\RenewDocumentEnvironment{#1}{+!b}{% |
| 2096 |
\NoFonts\expandafter\MMLVerbMathToks\expandafter{##1}{#1}\EndNoFonts% |
| 2097 |
}{} |
| 2098 |
}{}% |
| 2099 |
} |
| 2100 |
|
| 2101 |
\newcommand\MMLVerbEquation[1]{% |
| 2102 |
\cs_if_exist:cTF{#1}{ |
| 2103 |
\expandafter\let\csname old#1\expandafter\endcsname\csname #1\endcsname |
| 2104 |
\expandafter\let\csname endold#1\expandafter\endcsname\csname end#1\endcsname |
| 2105 |
\RenewDocumentEnvironment{#1}{+!b}{% |
| 2106 |
\ifmmode\begin{old#1}##1\end{old#1}\else% |
| 2107 |
\NoFonts\expandafter\MMLVerbMathToksEquation\expandafter{##1}{#1}\EndNoFonts% |
| 2108 |
\fi |
| 2109 |
}{} |
| 2110 |
}{}% |
| 2111 |
} |
| 2112 |
|
| 2113 |
|
| 2114 |
\ExplSyntaxOff |
| 2115 |
|
| 2116 |
\MMLVerbEquation{equation} |
| 2117 |
% \MMLVerbEquation{equation*} |
| 2118 |
|
| 2119 |
\fi |
| 2120 |
>>> |
| 2121 |
|
| 2122 |
\<configure html-mml amsmath\><<< |
| 2123 |
\:CheckOption{texsource}\if:Option |
| 2124 |
|
| 2125 |
% we must handle equations separatelly. |
| 2126 |
\renewcommand\MMLVerbMathToksEquation[2]{% |
| 2127 |
\mmlalteqtoks{\begin{#2} |
| 2128 |
#1 |
| 2129 |
\end{#2}}% |
| 2130 |
\begingroup% |
| 2131 |
\def\@tempa{#2}% |
| 2132 |
\def\@equationname{equation}% |
| 2133 |
\def\mlabeledtr{mtr} |
| 2134 |
\def\swapmlabeledtr##1##2{##2\HCode{</\a:mathml mtd><\a:mathml mtd>}##1}% |
| 2135 |
\ifx\@equationname\@tempa% |
| 2136 |
\ifOption{mathjax}{% |
| 2137 |
\def\mlabeledtr{mlabeledtr}% this element can be used to print the equation number, but it is supported only by MathJax |
| 2138 |
\def\swapmlabeledtr##1##2{##1\HCode{</\a:mathml mtd><\a:mathml mtd>}##2}% |
| 2139 |
}{}% |
| 2140 |
\fi |
| 2141 |
\ifvmode\IgnorePar\fi\EndP\Configure{@math}{display="block"}\DviMath\DisplayMathtrue\HCode{<\a:mathml semantics><\a:mathml mrow><\a:mathml mtable><\a:mathml \mlabeledtr><\a:mathml mtd>}% |
| 2142 |
\Configure{$}{}{}{}% |
| 2143 |
\Configure{$$}{}{}{}% |
| 2144 |
\@eqnswfalse% Disable duplicate equation number in the first equation in the document |
| 2145 |
\ifx\@equationname\@tempa% |
| 2146 |
\incr@eqnum% |
| 2147 |
\fi |
| 2148 |
\swapmlabeledtr{% |
| 2149 |
\ifx\@equationname\@tempa% |
| 2150 |
\print@eqnum% |
| 2151 |
\fi% |
| 2152 |
}{% |
| 2153 |
\mathdisplay{#2}% |
| 2154 |
#1% |
| 2155 |
\endmathdisplay{#2}% |
| 2156 |
}% |
| 2157 |
\HCode{</\a:mathml mtd></\a:mathml \mlabeledtr></\a:mathml mtable></\a:mathml mrow><\a:mathml annotation encoding="application/x-tex">}% |
| 2158 |
\HCode{\mmleqtoks}% |
| 2159 |
\HCode{</\a:mathml annotation></\a:mathml semantics>}% |
| 2160 |
\EndDviMath% |
| 2161 |
\endgroup% |
| 2162 |
} |
| 2163 |
|
| 2164 |
% \MMLVerbMath{subarray} |
| 2165 |
% \MMLVerbMath{smallmatrix} |
| 2166 |
% \MMLVerbMath{matrix} |
| 2167 |
% \MMLVerbMath{pmatrix} |
| 2168 |
% \MMLVerbMath{bmatrix} |
| 2169 |
% \MMLVerbMath{Bmatrix} |
| 2170 |
% \MMLVerbMath{vmatrix} |
| 2171 |
% \MMLVerbMath{Vmatrix} |
| 2172 |
% \MMLVerbMath{cases} |
| 2173 |
% \MMLVerbMath{subequations} |
| 2174 |
% \MMLVerbMath{aligned} |
| 2175 |
% \MMLVerbMath{alignedat} |
| 2176 |
\MMLVerbMath{gathered} |
| 2177 |
\MMLVerbMath{gather} |
| 2178 |
\MMLVerbMath{gather*} |
| 2179 |
\MMLVerbMath{alignat} |
| 2180 |
\MMLVerbMath{alignat*} |
| 2181 |
\MMLVerbMath{xalignat} |
| 2182 |
\MMLVerbMath{xalignat*} |
| 2183 |
\MMLVerbMath{xxalignat} |
| 2184 |
\MMLVerbMath{align} |
| 2185 |
\MMLVerbMath{align*} |
| 2186 |
\MMLVerbMath{flalign} |
| 2187 |
\MMLVerbMath{flalign*} |
| 2188 |
% \MMLVerbMath{split} |
| 2189 |
\MMLVerbMath{multline} |
| 2190 |
\MMLVerbMath{multline*} |
| 2191 |
% equations fails with errors, even though it worked in a .cfg |
| 2192 |
% I will need to investigate it more |
| 2193 |
\MMLVerbEquation{equation} |
| 2194 |
\MMLVerbEquation{equation*} |
| 2195 |
\MMLVerbMath{math} |
| 2196 |
\MMLVerbMath{displaymath} |
| 2197 |
\MMLVerbMath{eqnarray} |
| 2198 |
\MMLVerbMath{eqnarray*} |
| 2199 |
|
| 2200 |
\def\MML:DisplayMath#1\]{\begin{equation*}#1\end{equation*}} |
| 2201 |
|
| 2202 |
\AtBeginDocument{ |
| 2203 |
\DeclareRobustCommand\[{\MML:DisplayMath} |
| 2204 |
\DeclareRobustCommand\]{} |
| 2205 |
} |
| 2206 |
\fi |
| 2207 |
>>> |
| 2208 |
|
| 2209 |
%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 2210 |
\subsection{plain.sty} |
| 2211 |
%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 2212 |
|
| 2213 |
|
| 2214 |
|
| 2215 |
|
| 2216 |
\<mathml plain\><<< |
| 2217 |
\Configure{eqalign} |
| 2218 |
{\HCode{<\a:mathml mtable \mml:class="eqalign">}} |
| 2219 |
{\HCode{</\a:mathml mtable>}} |
| 2220 |
{\HCode{<\a:mathml mtr \Hnewline \mml:class="eqalign">}} |
| 2221 |
{\IgnorePar\HCode{</\a:mathml mtr>}} |
| 2222 |
{\HCode{\ifnum \HCol=3 <\a:mathml mtd\Hnewline |
| 2223 |
\mml:class="eqalign3"></\a:mathml mtd>\fi |
| 2224 |
<\a:mathml mtd \Hnewline \mml:class="eqalign\HCol">}} |
| 2225 |
{\HCode{</\a:mathml mtd>}} |
| 2226 |
>>> |
| 2227 |
|
| 2228 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 2229 |
\subsection{Palin + LaTeX} |
| 2230 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 2231 |
|
| 2232 |
The default \verb'\left' and \verb'\right' in their default definition |
| 2233 |
with tex produce multi-part delimiters, from cmex, on large |
| 2234 |
subformulas. Hence, the `'.' below is needed. |
| 2235 |
|
| 2236 |
\<plain,latex mathml\><<< |
| 2237 |
\def\:temp#1{\a:left{#1}\o:left:.\b:left{#1}} \HLet\left|=\:temp |
| 2238 |
\def\:temp#1{\a:right{#1}\o:right:.\b:right{#1}}\HLet\right|=\:temp |
| 2239 |
\Configure{left} |
| 2240 |
{} |
| 2241 |
{\HCode{<\a:mathml mrow><\a:mathml mo \a:mathml fence="true" \a:mathml form="prefix">% |
| 2242 |
|<lr del 1|></\a:mathml mo>}\bgroup |
| 2243 |
\HCode{<\a:mathml mrow>}\bgroup} |
| 2244 |
\Configure{right} |
| 2245 |
{\egroup\egroup}%{\egroup\Send{GROUP}{0}{ \a:mathml close=""\space}\egroup} |
| 2246 |
{\HCode{</\a:mathml mrow><\a:mathml mo \a:mathml fence="true" \a:mathml form="postfix">|<lr del 1|></\a:mathml mo></\a:mathml mrow>}} |
| 2247 |
\def\def:DEL#1{\def\:DEL{#1}} |
| 2248 |
\def\check:DEL#1#2{\def\:tempa{#1}\ifx \:tempa\:DEL \def\:DEL{#2}\fi} |
| 2249 |
\NewConfigure{mfenced}[2]{\append:defI\def:DEL{\check:DEL{#1}{#2}}} |
| 2250 |
|</bigl, /bigr,... for mathml|> |
| 2251 |
\:CheckOption{new-accents} \if:Option \else |
| 2252 |
|<config mathml accents|> |
| 2253 |
\fi |
| 2254 |
\def\mathinner#1{\Tg<\a:mathml mrow |
| 2255 |
\mml:class="mathinner">#1\Tg</\a:mathml mrow>} |
| 2256 |
>>> |
| 2257 |
|
| 2258 |
|
| 2259 |
\<configure mathml etex4ht\><<< |
| 2260 |
\def\:tempc#1{\a:middle\mathrel{\left:right#1\:EMPTY}\b:middle} |
| 2261 |
\HLet\middle=\:tempc |
| 2262 |
\NewConfigure{middle}{2} |
| 2263 |
\Configure{middle} |
| 2264 |
{\bgroup |
| 2265 |
\Configure{mathrel}{*} |
| 2266 |
{<mo \mml:class="MathClass-rel" |
| 2267 |
fence="true" stretchy="true" >} |
| 2268 |
{</mo>} |
| 2269 |
{\Configure{mathrel}{}{}{}{}}% |
| 2270 |
} |
| 2271 |
{\egroup} |
| 2272 |
>>> |
| 2273 |
|
| 2274 |
|
| 2275 |
The \verb+\root ...\of {...}+ creates the following structure. |
| 2276 |
|
| 2277 |
\begin{verbatim} |
| 2278 |
PUSH |
| 2279 |
...root value... |
| 2280 |
POP |
| 2281 |
PUSH |
| 2282 |
PUSH |
| 2283 |
PUSH |
| 2284 |
...root sign characters with PUSH-POP... |
| 2285 |
POP |
| 2286 |
PUSH |
| 2287 |
RIGHT4: 15213546 |
| 2288 |
DOWN3: -1553322 |
| 2289 |
PUT_RULE: height: 26213 |
| 2290 |
length: 1197667 |
| 2291 |
DOWN3: 1553322 |
| 2292 |
PUSH |
| 2293 |
...root content... |
| 2294 |
POP |
| 2295 |
POP |
| 2296 |
POP |
| 2297 |
POP |
| 2298 |
\end{verbatim} |
| 2299 |
|
| 2300 |
|
| 2301 |
|
| 2302 |
\<plain,latex mathml\><<< |
| 2303 |
\Configure{root}{\rev:root}{}{} |
| 2304 |
\def\rev:root #1\b:root#2\c:root{ |
| 2305 |
\Tg<\a:mathml mroot>{\Tg<\a:mathml mrow\Hnewline>#2\Tg</\a:mathml mrow>}% |
| 2306 |
{\Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>}\Tg</\a:mathml mroot>} |
| 2307 |
\def\AccentMath#1{\relax\ifmmode #1\else $#1$\fi} |
| 2308 |
>>> |
| 2309 |
|
| 2310 |
\<lr del 1\><<< |
| 2311 |
\expandafter |
| 2312 |
\ifx \csname \string#1:lr del\endcsname\relax #1\else |
| 2313 |
\csname \string#1:lr del\endcsname\fi |
| 2314 |
>>> |
| 2315 |
|
| 2316 |
\<lr del 2\><<< |
| 2317 |
\expandafter |
| 2318 |
\ifx \csname \string#2:lr del\endcsname\relax #2\else |
| 2319 |
\csname \string#2:lr del\endcsname\fi |
| 2320 |
>>> |
| 2321 |
|
| 2322 |
|
| 2323 |
\<lr del 3\><<< |
| 2324 |
\expandafter |
| 2325 |
\ifx \csname \string#3:lr del\endcsname\relax #3\else |
| 2326 |
\csname \string#3:lr del\endcsname\fi |
| 2327 |
>>> |
| 2328 |
|
| 2329 |
|
| 2330 |
\<plain,latex mathml\><<< |
| 2331 |
\NewConfigure{mfenced}[2]{\expandafter |
| 2332 |
\def\csname \string#1:lr del\endcsname{#2}} |
| 2333 |
|<plain,latex mfenced|> |
| 2334 |
>>> |
| 2335 |
|
| 2336 |
\<amsmath mathml\><<< |
| 2337 |
\Configure{mfenced}{\lvert}{\string&\#x007C;} |%vertical line|% |
| 2338 |
\Configure{mfenced}{\rvert}{\string&\#x007C;} |%double vertical line|% |
| 2339 |
\Configure{mfenced}{\lVert}{\string&\#x2016;} |
| 2340 |
\Configure{mfenced}{\rVert}{\string&\#x2016;} |
| 2341 |
>>> |
| 2342 |
|
| 2343 |
\<amstex.sty mathml\><<< |
| 2344 |
\Configure{mfenced}{\lvert}{\string&\#x007C;} |
| 2345 |
\Configure{mfenced}{\rvert}{\string&\#x007C;} |
| 2346 |
\Configure{mfenced}{\lVert}{\string&\#x2016;} |
| 2347 |
\Configure{mfenced}{\rVert}{\string&\#x2016;} |
| 2348 |
>>> |
| 2349 |
|
| 2350 |
|
| 2351 |
|
| 2352 |
|
| 2353 |
|
| 2354 |
\<plain,latex mfenced\><<< |
| 2355 |
\Configure{mfenced}{\||}{\string&\#x2225;} |
| 2356 |
\Configure{mfenced}{.}{} |
| 2357 |
\Configure{mfenced}{\langle}{\string&\#x27E8;} |%lang|% |
| 2358 |
\Configure{mfenced}{\rangle}{\string&\#x27E9;} |%rang|% |
| 2359 |
\Configure{mfenced}{\vert}{||} |
| 2360 |
\edef\:temp{\noexpand\Configure{mfenced}{\noexpand\{}{\string{}}\:temp |
| 2361 |
\edef\:temp{\noexpand\Configure{mfenced}{\noexpand\}}{\string}}}\:temp |
| 2362 |
\edef\:temp{\noexpand |
| 2363 |
\Configure{mfenced}{\noexpand\lbrace}{\string{}}\:temp |
| 2364 |
\edef\:temp{\noexpand |
| 2365 |
\Configure{mfenced}{\noexpand\rbrace}{\string}}}\:temp |
| 2366 |
\Configure{mfenced}{<}{\string&\#x003C;} |%lt|% |
| 2367 |
\Configure{mfenced}{>}{\string&\#x003E;} |%gt|% |
| 2368 |
\Configure{mfenced}{\lceil}{\string&\#x2308;} |
| 2369 |
\Configure{mfenced}{\rceil}{\string&\#x2309;} |
| 2370 |
\Configure{mfenced}{\lfloor}{\string&\#x230A;} |
| 2371 |
\Configure{mfenced}{\rfloor}{\string&\#x230B;} |
| 2372 |
\Configure{mfenced}{\Vert}{\string&\#x2225;} |
| 2373 |
\Configure{mfenced}{\rgroup}{)} |
| 2374 |
\Configure{mfenced}{\lgroup}{(} |
| 2375 |
\Configure{mfenced}{\bracevert}{||} |
| 2376 |
\Configure{mfenced}{\bracevert}{||} |
| 2377 |
\Configure{mfenced}{\downarrow}{\string&\#x2193;} |
| 2378 |
\Configure{mfenced}{\uparrow}{\string&\#x2191;} |
| 2379 |
\Configure{mfenced}{\Uparrow}{\string&\#x21D1;} |
| 2380 |
\Configure{mfenced}{\updownarrow}{\string&\#x2195;} |
| 2381 |
\Configure{mfenced}{\Updownarrow}{\string&\#x21D5;} |
| 2382 |
\Configure{mfenced}{\Downarrow}{\string&\#x21D3;} |
| 2383 |
\Configure{mfenced}{\backslash}{\string&\#x2216;} |
| 2384 |
\Configure{mfenced}{\rmoustache}{\string&\#x25DD;} |
| 2385 |
\Configure{mfenced}{\lmoustache}{\string&\#x25DC;} |
| 2386 |
\Configure{mfenced}{\Arrowvert}{\string&\#x2225;} |
| 2387 |
\Configure{mfenced}{\arrowvert}{\string&\#x007C;} |
| 2388 |
>>> |
| 2389 |
|
| 2390 |
% \def\:tempa{\{}\ifx \:tempa\:DEL \let\:DEL\lbrc: \else |
| 2391 |
% \def\:tempa{\}}\ifx \:tempa\:DEL \let\:DEL\rbrc: \else |
| 2392 |
% \def\:tempa{<}\ifx \:tempa\:DEL \def\:DEL{\string<}\else |
| 2393 |
% \def\:tempa{>}\ifx \:tempa\:DEL \def\:DEL{\string>}% |
| 2394 |
% \fi\fi\fi\fi } |
| 2395 |
% \edef\lbrc:{\string{} \edef\rbrc:{\string}} |
| 2396 |
|
| 2397 |
% \HCode{\string#1;}% |
| 2398 |
|
| 2399 |
%%%%%%%%%%%%%%%%%%%%% |
| 2400 |
\subsection{Amsmath} |
| 2401 |
%%%%%%%%%%%%%%%%%%%%% |
| 2402 |
|
| 2403 |
|
| 2404 |
\<configure html-mml amsmath\><<< |
| 2405 |
\Configure{@begin} |
| 2406 |
{split} |
| 2407 |
{\let\tagform@=\:gobble } |
| 2408 |
>>> |
| 2409 |
|
| 2410 |
\<amsmath mathml\><<< |
| 2411 |
\Configure{split} |
| 2412 |
{\HCode{<\a:mathml mtable \Hnewline |
| 2413 |
\a:mathml columnalign="right left" |
| 2414 |
\mml:class="split">}} |
| 2415 |
{\ifvmode\IgnorePar\fi \HCode{</\a:mathml mtable>}} |
| 2416 |
{\HCode{<\a:mathml mtr \mml:class="split-mtr">}} |
| 2417 |
{\HCode{</\a:mathml mtr>}} |
| 2418 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="split-mtd">}} |
| 2419 |
{\HCode{</\a:mathml mtd>}} |
| 2420 |
>>> |
| 2421 |
|
| 2422 |
|
| 2423 |
|
| 2424 |
\<amsmath mathml\><<< |
| 2425 |
\Configure{multline} |
| 2426 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" \mml:class="multline">}} |
| 2427 |
{\HCode{</\a:mathml mtable>}} |
| 2428 |
{\HCode{<\a:mathml mtr>% |
| 2429 |
<\a:mathml mtd\Hnewline \mml:class="multline">}} |
| 2430 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}} |
| 2431 |
{\HCode{</\a:mathml mtd><\a:mathml mtd>}} |
| 2432 |
{} |
| 2433 |
\Configure{multline*} |
| 2434 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" \mml:class="multline-star">}} |
| 2435 |
{\HCode{</\a:mathml mtable>}} |
| 2436 |
{\HCode{<\a:mathml mtr><\a:mathml mtd\Hnewline |
| 2437 |
\mml:class="multline-star">}} |
| 2438 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}} |
| 2439 |
\Configure{gather} |
| 2440 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" \mml:class="gather">}} |
| 2441 |
{\HCode{</\a:mathml mtable>}} |
| 2442 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2443 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 2444 |
\Configure{gather*} |
| 2445 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" \mml:class="gather-star">}} |
| 2446 |
{\HCode{</\a:mathml mtable>}} |
| 2447 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2448 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 2449 |
\Configure{subarray} |
| 2450 |
{\HCode{<\a:mathml mtable \mml:class="subarray\if c\Hlcr-c\fi" |
| 2451 |
\a:mathml rowspacing="0" |
| 2452 |
\if c\Hlcr \a:mathml columnalign="center"\fi>}} |
| 2453 |
{\HCode{</\a:mathml mtable>}} |
| 2454 |
{\HCode{<\a:mathml mtr><\a:mathml mtd>}} |
| 2455 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}} |
| 2456 |
\Configure{smallmatrix} |
| 2457 |
{\HCode{<\a:mathml mtable>}} |
| 2458 |
{\HCode{</\a:mathml mtable>}} |
| 2459 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="smallmatrix">}} |
| 2460 |
{\HCode{</\a:mathml mtr>}} |
| 2461 |
{\HCode{\Hnewline<\a:mathml mtd>}} |
| 2462 |
{\HCode{</\a:mathml mtd>}} |
| 2463 |
\def\:tempc#1#2{% |
| 2464 |
\ConfigureEnv{#1} |
| 2465 |
{\def\end:al:env{}\ifmmode\else |
| 2466 |
\ifvmode\else \def\end:al:env{\par\ShowPar\IgnoreIndent}\fi\fi} |
| 2467 |
{\end:al:env } |
| 2468 |
{}{}% |
| 2469 |
\Configure{#1} |
| 2470 |
{\IgnorePar |
| 2471 |
\ifvmode \EndP \else \EndP \HCode{<!--tex4ht:inline-->}\fi |
| 2472 |
\ifmathml |
| 2473 |
\Tg<\a:mathml mrow>\def\end:mathalign{\Tg</\a:mathml mrow>}% |
| 2474 |
\else |
| 2475 |
\Configure{@math}{|<block display|>}\DviMath |
| 2476 |
\def\end:mathalign{\EndDviMath \DisplayMathfalse}% |
| 2477 |
\DisplayMathtrue |
| 2478 |
\fi |
| 2479 |
\HCode{<\a:mathml mtable\Hnewline |
| 2480 |
\a:mathml displaystyle="true" \a:mathml columnalign="left" \mml:class="#2">}} |
| 2481 |
{\HCode{</\a:mathml mtable>}\end:mathalign } |
| 2482 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2483 |
{\HCode{<\a:mathml mtd\Hnewline |
| 2484 |
|<rightward align col|>% |
| 2485 |
\mml:class="align-\ifnum \HCol>\maxfields@ label\else |
| 2486 |
\ifodd\HCol\space odd\else even\fi |
| 2487 |
\fi">}} |
| 2488 |
{\HCode{|<extra align col sep|></\a:mathml mtd>}}} |
| 2489 |
\:tempc{align}{align} |
| 2490 |
\:tempc{alignat}{alignat} |
| 2491 |
\:tempc{xalignat}{xalignat} |
| 2492 |
\:tempc{xxalignat}{xxalignat} |
| 2493 |
\:tempc{flalign}{flalign} |
| 2494 |
\:tempc{align*}{align-star} |
| 2495 |
\:tempc{alignat*}{alignat-star} |
| 2496 |
\:tempc{xalignat*}{xalignat-star} |
| 2497 |
\:tempc{flalign*}{flalign-star} |
| 2498 |
>>> |
| 2499 |
|
| 2500 |
|
| 2501 |
|
| 2502 |
\<amsmath mathml\><<< |
| 2503 |
\Configure{gathered} |
| 2504 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="gathered" \a:mathml displaystyle="true" \mtable:align:attribute>}} |
| 2505 |
{\HCode{</\a:mathml mtable>}} |
| 2506 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2507 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 2508 |
>>> |
| 2509 |
|
| 2510 |
|
| 2511 |
|
| 2512 |
\<configure html-mml amsmath\><<< |
| 2513 |
\Css{mtd.align-odd{margin-left:2em; text-align:right;}} |
| 2514 |
\Css{mtd.align-even{margin-right:2em; text-align:left;}} |
| 2515 |
>>> |
| 2516 |
|
| 2517 |
\<extra align col sep\><<< |
| 2518 |
\ifodd\HCol\space\else |
| 2519 |
<\a:mathml mspace width="2em"/>\fi |
| 2520 |
>>> |
| 2521 |
|
| 2522 |
\<rightward align col\><<< |
| 2523 |
\ifodd\HCol \a:mathml columnalign="right" \fi |
| 2524 |
>>> |
| 2525 |
|
| 2526 |
Setting \verb+#1+ below within mrow is problematic in the sense that |
| 2527 |
arrows don't stretch over multi-characters content \verb+#2+. |
| 2528 |
A \verb+accent="true"+ move the arrow lower, but also distribute the |
| 2529 |
characters further apart. |
| 2530 |
|
| 2531 |
\<under arrow\><<< |
| 2532 |
\Tg<\a:mathml munder>% |
| 2533 |
\Tg<\a:mathml mrow\Hnewline>#2\Tg</\a:mathml mrow>% |
| 2534 |
#1% |
| 2535 |
\Tg</\a:mathml munder>% |
| 2536 |
>>> |
| 2537 |
|
| 2538 |
\<over arrow\><<< |
| 2539 |
\Tg<\a:mathml mover class="overarrow">% |
| 2540 |
\Tg<\a:mathml mrow\Hnewline>{#2#3}\Tg</\a:mathml mrow>% |
| 2541 |
#1% |
| 2542 |
\Tg</\a:mathml mover>% |
| 2543 |
>>> |
| 2544 |
|
| 2545 |
|
| 2546 |
|
| 2547 |
|
| 2548 |
% \Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>% |
| 2549 |
% \Tg<\a:mathml mrow>#1\Tg</\a:mathml mrow>% |
| 2550 |
|
| 2551 |
|
| 2552 |
\<arr amsmath, amstex1\><<< |
| 2553 |
\Configure{underarrow@} |
| 2554 |
{\Tg<\a:mathml munder>\Tg<\a:mathml mrow\Hnewline>} |
| 2555 |
{\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>} |
| 2556 |
{\Tg</\a:mathml mrow>\Tg</\a:mathml munder>} |
| 2557 |
\Configure{overarrow@} |
| 2558 |
{\Tg<\a:mathml mover accent="true">\Tg<\a:mathml mrow\Hnewline>} |
| 2559 |
{\Tg</\a:mathml mrow>\Tg<\a:mathml mrow>} |
| 2560 |
{\Tg</\a:mathml mrow>\Tg</\a:mathml mover>} |
| 2561 |
\def\:tempc#1#2#3{\a:overarrow@ |
| 2562 |
\hbox{$\m@th#2#3$}\b:overarrow@ |
| 2563 |
\hbox{#1#2}\c:overarrow@ |
| 2564 |
} |
| 2565 |
\HLet\overarrow@\:tempc |
| 2566 |
>>> |
| 2567 |
|
| 2568 |
|
| 2569 |
|
| 2570 |
|
| 2571 |
|
| 2572 |
\<configure mathml amstex1\><<< |
| 2573 |
\ifx \o:overrightarrow:\:UnDef\else |
| 2574 |
\HRestore\overrightarrow |
| 2575 |
\HRestore\overleftarrow |
| 2576 |
\HRestore\overleftrightarrow |
| 2577 |
\fi |
| 2578 |
>>> |
| 2579 |
|
| 2580 |
|
| 2581 |
|
| 2582 |
\<amsmath html-mml jan 2000NO\><<< |
| 2583 |
\HRestore\overrightarrow |
| 2584 |
\HRestore\overleftarrow |
| 2585 |
\HRestore\overleftrightarrow |
| 2586 |
>>> |
| 2587 |
|
| 2588 |
\<amsmath html-mml july 2000NO\><<< |
| 2589 |
\HRestore\overrightarrow |
| 2590 |
\HRestore\overleftarrow |
| 2591 |
\HRestore\overleftrightarrow |
| 2592 |
>>> |
| 2593 |
|
| 2594 |
% \HRestore\underrightarrow |
| 2595 |
% \HRestore\underleftarrow |
| 2596 |
% \HRestore\underleftrightarrow |
| 2597 |
|
| 2598 |
|
| 2599 |
|
| 2600 |
|
| 2601 |
\<\><<< |
| 2602 |
\def\:tempc{\mathpalette{\overarrow@\rightarrow}} |
| 2603 |
\HLet\overrightarrow=\:tempc |
| 2604 |
\def\:tempc{\mathpalette{\overarrow@\leftarrow}} |
| 2605 |
\HLet\overleftarrow=\:tempc |
| 2606 |
\def\:tempc{\mathpalette{\overarrow@\leftrightarrow}} |
| 2607 |
\HLet\overleftrightarrow=\:tempc |
| 2608 |
|
| 2609 |
\def\:tempc{\mathpalette{\underarrow@\rightarrow}} |
| 2610 |
\HLet\underrightarrow=\:tempc |
| 2611 |
\def\:tempc{\mathpalette{\underarrow@\leftarrow}} |
| 2612 |
\HLet\underleftarrow=\:tempc |
| 2613 |
\def\:tempc{\mathpalette{\underarrow@\leftrightarrow}} |
| 2614 |
\HLet\underleftrightarrow=\:tempc |
| 2615 |
>>> |
| 2616 |
|
| 2617 |
|
| 2618 |
Replace with |
| 2619 |
\Link[http://www.unicode.org/charts/PDF/U27F0.pdf]{}{}stretching |
| 2620 |
arrows\EndLink{} once they work. It was \verb+\rightarrow+ (U-2192) |
| 2621 |
before going to \verb+\HCode{&\#x20D7;}+. |
| 2622 |
(... suggested |
| 2623 |
to replace it with |
| 2624 |
the diacritical one: \verb+⃗+. I t solves two problems. The arrow is |
| 2625 |
lower and the spacing between a subscript and a vector is |
| 2626 |
reduced.) |
| 2627 |
|
| 2628 |
\<mathml plain,fontmath\><<< |
| 2629 |
\Configure{overrightarrow} |
| 2630 |
{\leavevmode\hbox\bgroup$\Tg<\a:mathml mover accent="true" class="overrightarrow">% |
| 2631 |
\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2632 |
{\Tg</\a:mathml mrow>\HCode{<\a:mathml mo>&\#x2192;</\a:mathml mo>}% |
| 2633 |
\Tg</\a:mathml mover>$\egroup} |
| 2634 |
\Configure{overleftarrow} |
| 2635 |
{\leavevmode\hbox\bgroup$\Tg<\a:mathml mover accent="true" class="overleftarrow">% |
| 2636 |
\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2637 |
{\Tg</\a:mathml mrow>\HCode{<\a:mathml mo>&\#x2190;</\a:mathml mo>}% |
| 2638 |
\Tg</\a:mathml mover>$\egroup} |
| 2639 |
>>> |
| 2640 |
|
| 2641 |
|
| 2642 |
\<amsmath mathml\><<< |
| 2643 |
\Configure{[]}{\begin{equation*}}{\end{equation*}} |
| 2644 |
>>> |
| 2645 |
|
| 2646 |
\<amsmath mathml\><<< |
| 2647 |
\Configure{underrightarrow} |
| 2648 |
{\Tg<\a:mathml munder>\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2649 |
{\Tg</\a:mathml mrow>\mathop{\rightarrow}\Tg</\a:mathml munder>} |
| 2650 |
\Configure{underleftarrow} |
| 2651 |
{\Tg<\a:mathml munder>\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2652 |
{\Tg</\a:mathml mrow>\mathop{\leftarrow}\Tg</\a:mathml munder>} |
| 2653 |
>>> |
| 2654 |
|
| 2655 |
|
| 2656 |
\<amsmath mathml\><<< |
| 2657 |
\Configure{overleftrightarrow} |
| 2658 |
{\Tg<\a:mathml mover class="overleftrightarrow">\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2659 |
{\Tg</\a:mathml mrow>\mathop{\HCode{&\#x20E1;}}\Tg</\a:mathml mover>} |
| 2660 |
\Configure{underleftrightarrow} |
| 2661 |
{\Tg<\a:mathml munder>\Tg<\a:mathml mrow\Hnewline>\:gobble} |
| 2662 |
{\Tg</\a:mathml mrow>\mathop{\leftrightarrow}\Tg</\a:mathml munder>} |
| 2663 |
>>> |
| 2664 |
|
| 2665 |
|
| 2666 |
|
| 2667 |
|
| 2668 |
|
| 2669 |
|
| 2670 |
\<\><<< |
| 2671 |
\def\underarrow:#1#2#3{|<under arrow|>} |
| 2672 |
\def\overarrow:#1#2#3{|<over arrow|>} |
| 2673 |
\def\:tempc{\mathpalette{\overarrow:\rightarrow}} |
| 2674 |
\HLet\overrightarrow=\:tempc |
| 2675 |
\def\:tempc{\mathpalette{\overarrow:\leftarrow}} |
| 2676 |
\HLet\overleftarrow=\:tempc |
| 2677 |
\def\:tempc{\mathpalette{\overarrow:\leftrightarrow}} |
| 2678 |
\HLet\overleftrightarrow=\:tempc |
| 2679 |
>>> |
| 2680 |
|
| 2681 |
\<\><<< |
| 2682 |
\def\:tempc{\mathpalette{\underarrow:\rightarrow}} |
| 2683 |
\HLet\underrightarrow=\:tempc |
| 2684 |
\def\:tempc{\mathpalette{\underarrow:\leftarrow}} |
| 2685 |
\HLet\underleftarrow=\:tempc |
| 2686 |
\def\:tempc{\mathpalette{\underarrow:\leftrightarrow}} |
| 2687 |
\HLet\underleftrightarrow=\:tempc |
| 2688 |
>>> |
| 2689 |
|
| 2690 |
|
| 2691 |
|
| 2692 |
\<amsmath mathml\><<< |
| 2693 |
|<mathml m:env|> |
| 2694 |
\renewcommand{\xrightarrow}[2][]{% |
| 2695 |
\Tg<\a:mathml munderover>% |
| 2696 |
\rightarrow |
| 2697 |
\Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>% |
| 2698 |
\Tg<\a:mathml mrow\Hnewline>#2\Tg</\a:mathml mrow>% |
| 2699 |
\Tg</\a:mathml munderover>}% |
| 2700 |
\renewcommand{\xleftarrow}[2][]{% |
| 2701 |
\Tg<\a:mathml munderover>% |
| 2702 |
\leftarrow |
| 2703 |
\Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>% |
| 2704 |
\Tg<\a:mathml mrow\Hnewline>#2\Tg</\a:mathml mrow>% |
| 2705 |
\Tg</\a:mathml munderover>}% |
| 2706 |
|
| 2707 |
\def\overset#1#2{{% |
| 2708 |
\Tg<\a:mathml mover class="overset">\Tg<\a:mathml |
| 2709 |
mrow\Hnewline>#2\Tg</\a:mathml mrow>% |
| 2710 |
\Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>% |
| 2711 |
\Tg</\a:mathml mover>}}% |
| 2712 |
\def\underset#1#2{{% |
| 2713 |
\Tg<\a:mathml munder>\Tg<\a:mathml mrow\Hnewline>#2\Tg</\a:mathml mrow>% |
| 2714 |
\Tg<\a:mathml mrow\Hnewline>#1\Tg</\a:mathml mrow>% |
| 2715 |
\Tg</\a:mathml munder>}}% |
| 2716 |
|
| 2717 |
\def\sideset#1#2#3{{\Tg<\a:mathml mrow \mml:class="sideset"\Hnewline |
| 2718 |
>{\HCode{}}#1{\HCode{}#3}#2\Tg</\a:mathml mrow>}} |
| 2719 |
\ConfigureEnv{eqxample}{}{}{}{} |
| 2720 |
\ConfigureEnv{gather*}{}{}{}{} |
| 2721 |
\ConfigureEnv{gathered}{}{}{}{} |
| 2722 |
\ConfigureEnv{matrix}{}{}{}{} |
| 2723 |
>>> |
| 2724 |
|
| 2725 |
The \verb'\HCode{}' in \verb'\sideset' is for catching superscripts and subscripts |
| 2726 |
|
| 2727 |
|
| 2728 |
|
| 2729 |
% \renewcommand{\hdotsfor}[1]{% |
| 2730 |
% \ifx[#1\@xp\shdots@for\else\hdots@for\@ne{#1}\fi} |
| 2731 |
% \def\shdots@for#1]{\hdots@for{#1}} |
| 2732 |
% \def\hdots@for#1#2{\multicolumn{#2}c% |
| 2733 |
% {\m@th\[email protected]\mkern-#1\dotsspace@ |
| 2734 |
% \xleaders\hbox{$\m@th\mkern#1\dotsspace@.\mkern#1\dotsspace@$}% |
| 2735 |
% \hfill |
| 2736 |
% \mkern-#1\dotsspace@}% |
| 2737 |
% } |
| 2738 |
|
| 2739 |
|
| 2740 |
|
| 2741 |
\<amsmath symbols\><<< |
| 2742 |
\def\:tempc{\HCode{<\a:mathml mspace width="0.2em"/>}\mathbin |
| 2743 |
{mod}\HCode{<\a:mathml mspace width="0.2em"/>}} |
| 2744 |
\HLet\bmod\:tempc |
| 2745 |
\def\:tempc#1{\allowbreak |
| 2746 |
\HCode{<\a:mathml mspace width="0.3em"/>}(#1)} |
| 2747 |
\HLet\pod=\:tempc |
| 2748 |
\def\:tempc#1{\pod{\mathop{mod}\HCode{<\a:mathml mspace width="0.3em"/>}#1}} |
| 2749 |
\HLet\pmod=\:tempc |
| 2750 |
\def\:tempc#1{\allowbreak |
| 2751 |
\HCode{<\a:mathml mspace width="0.3em"/>}\mathop |
| 2752 |
{mod}\HCode{<\a:mathml mspace width="0.3em"/>}#1} |
| 2753 |
\HLet\mod=\:tempc |
| 2754 |
>>> |
| 2755 |
|
| 2756 |
|
| 2757 |
%%%%%%%%%%%%%%%%%%%% |
| 2758 |
\subsection{amsopn} |
| 2759 |
%%%%%%%%%%%%%%%%%%%% |
| 2760 |
|
| 2761 |
|
| 2762 |
\marginpar{remove the following def in liu of xtpipes} |
| 2763 |
|
| 2764 |
\<amsopn / amstex.sty mathml\><<< |
| 2765 |
\def\:tempc{{\underrightarrow\lim}} \HLet\varinjlim\:tempc |
| 2766 |
\def\:tempc{{\underleftarrow\lim}} \HLet\varprojlim\:tempc |
| 2767 |
\def\:tempc{{\overline\lim}} \HLet\varlimsup\:tempc |
| 2768 |
\def\:tempc{{\underline\lim}} \HLet\varliminf\:tempc |
| 2769 |
>>> |
| 2770 |
|
| 2771 |
|
| 2772 |
\<amsopn / amstex.sty mathml\><<< |
| 2773 |
\def\:tempc#1#2#3{\hbox{{\mtexttrue |
| 2774 |
\HCode{<\a:mathml mrow\Hnewline |
| 2775 |
\mml:class="text"><\a:mathml mtext |
| 2776 |
\a:@mtext>}|<start mtext space|>\PauseMathClass |
| 2777 |
\Configure{$}{\EndPauseMathClass\mtextfalse |
| 2778 |
|<end mtext space|>\HCode{</\a:mathml mtext><\a:mathml |
| 2779 |
mrow\Hnewline \mml:class="math">}} |
| 2780 |
{\HCode{</\a:mathml mrow><\a:mathml mtext |
| 2781 |
\a:@mtext>}|<start mtext space|>\mtexttrue\PauseMathClass}{#1} |
| 2782 |
\let\f@size#2\selectfont #3}% |
| 2783 |
\mtextfalse \EndPauseMathClass |<end mtext space|>\HCode |
| 2784 |
{</\a:mathml mtext></\a:mathml mrow>}}} |
| 2785 |
\HLet\textdef@\:tempc |
| 2786 |
>>> |
| 2787 |
|
| 2788 |
|
| 2789 |
The original definitions for the following macros contain small spaces |
| 2790 |
\verb+\,+ in the names, we need to use explicit tags to support them |
| 2791 |
correctly. |
| 2792 |
|
| 2793 |
See \Link{https://github.com/michal-h21/make4ht/issues/133}{}this report\EndLink |
| 2794 |
for more details. |
| 2795 |
|
| 2796 |
|
| 2797 |
\<configure mathml amsopn\><<< |
| 2798 |
\def\:tempc{\qopname\relax m{\:limspaces{lim}{inf}}} |
| 2799 |
\HLet\liminf=\:tempc |
| 2800 |
\def\:tempc{\qopname\relax m{\:limspaces{lim}{sup}}} |
| 2801 |
\HLet\limsup=\:tempc |
| 2802 |
\def\:tempc{\qopname\relax m{\:limspaces{proj}{lim}}} |
| 2803 |
\HLet\projlim=\:tempc |
| 2804 |
\def\:tempc{\qopname\relax m{\:limspaces{inj}{lim}}} |
| 2805 |
\HLet\injlim=\:tempc |
| 2806 |
>>> |
| 2807 |
|
| 2808 |
\<configure mathml amsopn\><<< |
| 2809 |
\Configure{qopname} |
| 2810 |
{\Configure{mathop}{*} |
| 2811 |
{<\a:mathml mi \mml:class="qopname">} |
| 2812 |
{</\a:mathml mi><\a:mathml mo> &\#x2061;<!--FUNCTION APPLICATION--> </\a:mathml mo>} |
| 2813 |
{}} |
| 2814 |
>>> |
| 2815 |
|
| 2816 |
|
| 2817 |
|
| 2818 |
|
| 2819 |
Why originally the accents are defined within a group? (knuth answer |
| 2820 |
this in the texbook.) |
| 2821 |
|
| 2822 |
\<plain,latex mathml\><<< |
| 2823 |
\let\A:oalign|=\a:oalign |
| 2824 |
\let\B:oalign|=\b:oalign |
| 2825 |
\Configure{oalign} |
| 2826 |
{\ifmmode \Configure{$}{\Tg<\a:mathml mrow\Hnewline>}% |
| 2827 |
{\Tg</\a:mathml mrow>}{}% |
| 2828 |
\let\halign|=\TeXhalign |
| 2829 |
\Tg<\a:mathml mrow\Hnewline \mml:class="oalign">\else\A:oalign |
| 2830 |
\fi} |
| 2831 |
{\ifmmode \Tg</\a:mathml mrow>\else\B:oalign\fi} |
| 2832 |
>>> |
| 2833 |
|
| 2834 |
|
| 2835 |
|
| 2836 |
The following CSS caused too large whitespace around functions |
| 2837 |
%\Css{mi.qopname + mo{margin-left:0.3em}} |
| 2838 |
%\Css{mi + mi.qopname{margin-left:0.3em}} |
| 2839 |
|
| 2840 |
|
| 2841 |
%%%%%%%%%%%%%%%%% |
| 2842 |
\subsection{mathtools} |
| 2843 |
%%%%%%%%%%%%%%%%%% |
| 2844 |
|
| 2845 |
\<configure mathml mathtools\><<< |
| 2846 |
\Configure{MT_gathered_env} |
| 2847 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="MT-gathered-env">}} |
| 2848 |
{\HCode{</\a:mathml mtable>}} |
| 2849 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2850 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 2851 |
\ConfigureEnv{MT_gathered_env}{}{}{}{} |
| 2852 |
>>> |
| 2853 |
|
| 2854 |
\<configure mathml mathtools\><<< |
| 2855 |
\ConfigureEnv{gathered} |
| 2856 |
{% |
| 2857 |
\Configure{MT_gathered_env} |
| 2858 |
{\HCode{<\a:mathml mtable\Hnewline |
| 2859 |
\mml:class="gathered" columnalign="center" >}} |
| 2860 |
{\HCode{</\a:mathml mtable>}} |
| 2861 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2862 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}}% |
| 2863 |
} |
| 2864 |
{}{}{} |
| 2865 |
>>> |
| 2866 |
|
| 2867 |
\<configure mathml mathtools\><<< |
| 2868 |
\ConfigureEnv{lgathered} |
| 2869 |
{% |
| 2870 |
\Configure{MT_gathered_env} |
| 2871 |
{\HCode{<\a:mathml mtable\Hnewline |
| 2872 |
\mml:class="lgathered" columnalign="left" >}} |
| 2873 |
{\HCode{</\a:mathml mtable>}} |
| 2874 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2875 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}}% |
| 2876 |
} |
| 2877 |
{}{}{} |
| 2878 |
>>> |
| 2879 |
|
| 2880 |
|
| 2881 |
\<configure mathml mathtools\><<< |
| 2882 |
\ConfigureEnv{rgathered} |
| 2883 |
{% |
| 2884 |
\Configure{MT_gathered_env} |
| 2885 |
{\HCode{<\a:mathml mtable\Hnewline |
| 2886 |
\mml:class="rgathered" columnalign="right" >}} |
| 2887 |
{\HCode{</\a:mathml mtable>}} |
| 2888 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2889 |
{\HCode{\Hnewline<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}}% |
| 2890 |
} |
| 2891 |
{}{}{} |
| 2892 |
>>> |
| 2893 |
|
| 2894 |
|
| 2895 |
\<configure mathml mathtools\><<< |
| 2896 |
\ConfigureEnv{cases} |
| 2897 |
{\HCode{<\a:mathml mrow \mml:class="cases" >}} |
| 2898 |
{\HCode{</\a:mathml mrow>}} |
| 2899 |
{}{} |
| 2900 |
\Configure{dcases} |
| 2901 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="dcases">}} |
| 2902 |
{\HCode{</\a:mathml mtable>}} |
| 2903 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2904 |
{\HCode{\Hnewline<\a:mathml mtd columnalign="left">}} |
| 2905 |
{\HCode{</\a:mathml mtd>}} |
| 2906 |
\Configure{dcases*} |
| 2907 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="dcases-star">}} |
| 2908 |
{\HCode{</\a:mathml mtable>}} |
| 2909 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 2910 |
{\HCode{\Hnewline<\a:mathml mtd columnalign="left">}% |
| 2911 |
\ifnum\HCol=2 |
| 2912 |
\PauseMathClass |
| 2913 |
\HCode{<\a:mathml mtext>}% |
| 2914 |
% the content of this environment is displayed as text, we must switch back to the normal math processing |
| 2915 |
% in inline math |
| 2916 |
\Configure{$}{\EndPauseMathClass\HCode{</\a:mathml mtext>}}{\PauseMathClass\HCode{<\a:mathml mtext>}}{}% |
| 2917 |
\Configure{()}{\HCode{</\a:mathml mtext>}\EndPauseMathClass$}{$\PauseMathClass\HCode{<\a:mathml mtext>}}{}% |
| 2918 |
\fi |
| 2919 |
} |
| 2920 |
{\ifnum\HCol=2 |
| 2921 |
\EndPauseMathClass |
| 2922 |
\HCode{</\a:mathml mtext>}% |
| 2923 |
\fi |
| 2924 |
\HCode{</\a:mathml mtd>}} |
| 2925 |
>>> |
| 2926 |
|
| 2927 |
Fix MathML arrows with MathTools. |
| 2928 |
|
| 2929 |
\<configure mathml mathtools\><<< |
| 2930 |
% support bidirectional harpoons |
| 2931 |
\def\:leftrightharpoons{\HCode{<\a:mathml mo stretchy="true">}\PauseMathClass\x:unicode{21CC}\EndPauseMathClass\HCode{</\a:mathml mo>}} |
| 2932 |
\def\:righleftharpoons{\HCode{<\a:mathml mo stretchy="true">}\PauseMathClass\x:unicode{21CB}\EndPauseMathClass\HCode{</\a:mathml mo>}} |
| 2933 |
|
| 2934 |
\providecommand*\:xleftrightharpoons[2][]{% |
| 2935 |
\ext@arrow 3095\:leftrightharpoons{#1}{#2}} |
| 2936 |
|
| 2937 |
\providecommand*\:xrightleftharpoons[2][]{% |
| 2938 |
\ext@arrow 3095\:leftrightharpoons{#1}{#2}} |
| 2939 |
|
| 2940 |
\HLet\xleftrightharpoons\:xleftrightharpoons |
| 2941 |
\HLet\xrightleftharpoons\:xrightleftharpoons |
| 2942 |
|
| 2943 |
% correctly place text under and over arrows |
| 2944 |
\def\:tempa#1#2#3#4#5#6#7{% |
| 2945 |
\bgroup% |
| 2946 |
\def\relbar{}% remove relbar in arrow fills |
| 2947 |
\def\arrowfill@##1##2##3##4{##1##2##3##4}% remove arrowfill@, to prevent errors |
| 2948 |
\@ifempty{#7}{% |
| 2949 |
\HCode{<\a:mathml munder><\a:mathml mrow><\a:mathml mo stretchy="true">}\PauseMathClass#5{}\EndPauseMathClass\HCode{</\a:mathml mo></\a:mathml mrow><\a:mathml mrow>}#6\HCode{</\a:mathml mrow></\a:mathml munder>}% |
| 2950 |
}{% |
| 2951 |
\@ifempty{#6}{% |
| 2952 |
\HCode{<\a:mathml mover><\a:mathml mrow><\a:mathml mo stretchy="true">}\PauseMathClass#5{}\EndPauseMathClass\HCode{</\a:mathml mo></\a:mathml mrow><\a:mathml mrow>}#7\HCode{</\a:mathml mrow></\a:mathml mover>}% |
| 2953 |
}{% |
| 2954 |
\HCode{<\a:mathml munderover><\a:mathml mrow><\a:mathml mo stretchy="true">}\PauseMathClass#5{}\EndPauseMathClass\HCode{</\a:mathml mo></\a:mathml mrow><\a:mathml mrow>}#6\HCode{</\a:mathml mrow><\a:mathml mrow>}#7\HCode{</\a:mathml mrow></\a:mathml munderover>}% |
| 2955 |
}% |
| 2956 |
}% |
| 2957 |
\egroup |
| 2958 |
} |
| 2959 |
|
| 2960 |
\HLet\ext@arrow\:tempa |
| 2961 |
>>> |
| 2962 |
|
| 2963 |
%%%%%%%%%%%%%%%%%% |
| 2964 |
\section{Gaus} |
| 2965 |
%%%%%%%%%%%%%%%%%% |
| 2966 |
|
| 2967 |
|
| 2968 |
|
| 2969 |
\<configure mathml gauss\><<< |
| 2970 |
\Configure{gmatrix} |
| 2971 |
{\HCode{<\a:mathml mtable \mml:class="gmatrix-\g@environment">}} |
| 2972 |
{\HCode{</\a:mathml mtable>}} |
| 2973 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="gmatrix">}} |
| 2974 |
{\HCode{</\a:mathml mtr>}} |
| 2975 |
{\HCode{\Hnewline<\a:mathml mtd>}} |
| 2976 |
{\HCode{</\a:mathml mtd>}} |
| 2977 |
>>> |
| 2978 |
|
| 2979 |
\<configure mathml gauss\><<< |
| 2980 |
\Css{mtr.gmatrix mtd {margin-left:0em; margin-right:0em; |
| 2981 |
padding-left:0em; padding-right:0em; |
| 2982 |
text-indent:0pt; |
| 2983 |
}} |
| 2984 |
\Css{mfenced mtable {margin-left:0em; margin-right:0em; |
| 2985 |
padding-left:0em; padding-right:0em; |
| 2986 |
text-indent:0pt; |
| 2987 |
}} |
| 2988 |
>>> |
| 2989 |
|
| 2990 |
\<configure mathml gauss\><<< |
| 2991 |
\Configure{rowops} |
| 2992 |
{\HCode{<mtable class="rowops"> |
| 2993 |
<mtr><mtd columnspan="3"><mtext>Row ops:</mtext></mtd></mtr> |
| 2994 |
}} |
| 2995 |
{\HCode{</mtable>}} |
| 2996 |
\Configure{colops} |
| 2997 |
{\HCode{<mtable class="colops"> |
| 2998 |
<mtr><mtd columnspan="3"><mtext>Col ops:</mtext></mtd></mtr> |
| 2999 |
}} |
| 3000 |
{\HCode{</mtable>}} |
| 3001 |
\Css{mtable.rowops, mtable.colops { |
| 3002 |
margin-left:0.2em; |
| 3003 |
margin-right:0.2em; |
| 3004 |
font-size:75\%; |
| 3005 |
}} |
| 3006 |
\Css{mtable.rowops mtr, mtable.colops mtr, |
| 3007 |
mtable.rowops mtd, mtable.colops mtd |
| 3008 |
{ |
| 3009 |
margin:0em; padding:0em; |
| 3010 |
}} |
| 3011 |
\Configure{add} |
| 3012 |
{\HCode{<mtr><mtd>}\mbox{add }\HCode{</mtd><mtd>}} |
| 3013 |
{,\HCode{</mtd><mtd>}} |
| 3014 |
{\HCode{</mtd></mtr>}} |
| 3015 |
\Configure{mult} |
| 3016 |
{\HCode{<mtr><mtd>}\mbox{mult }\HCode{</mtd><mtd>}} |
| 3017 |
{,\HCode{</mtd><mtd>}} |
| 3018 |
{\HCode{</mtd></mtr>}} |
| 3019 |
\Configure{swap} |
| 3020 |
{\HCode{<mtr><mtd>}\mbox{swap }\HCode{</mtd><mtd>}} |
| 3021 |
{,\HCode{</mtd><mtd>}} |
| 3022 |
{\HCode{</mtd></mtr>}} |
| 3023 |
>>> |
| 3024 |
|
| 3025 |
%%%%%%%%%%%%%%%%%%%% |
| 3026 |
\section{Eqnarray} |
| 3027 |
%%%%%%%%%%%%%%%%%%%% |
| 3028 |
|
| 3029 |
Had `BASELINE' before `MIDDLE', but changed to conform with math |
| 3030 |
in page 252-- in intro to theory book. |
| 3031 |
|
| 3032 |
\<mathml latex\><<< |
| 3033 |
\ConfigureEnv{eqnarray} |
| 3034 |
{\ifvmode \IgnorePar \fi \EndP} |
| 3035 |
{\ifvmode \IgnorePar \fi \EndP \ShowPar \par} |
| 3036 |
{}{} |
| 3037 |
\Configure{eqnarray} |
| 3038 |
{\HCode{<\a:mathml mtable\Hnewline \a:mathml displaystyle="true" |
| 3039 |
\mml:class="eqnarray\ifx |
| 3040 |
\@seqncr\@eqncr\else-star\fi" |
| 3041 |
\a:mathml columnalign="right center left" >}}% |
| 3042 |
{\HCode{</\a:mathml mtable>}} |
| 3043 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 3044 |
{\Tg<\a:mathml mtd\Hnewline \mml:class="eqnarray-\HCol"> |
| 3045 |
\ifnum \HCol=4 |
| 3046 |
\Tg<\a:mathml mtext |
| 3047 |
\mml:class="eqnarray">|<start mtext space|>\PauseMathClass |
| 3048 |
\mtexttrue |
| 3049 |
|<config math within mtext|>% |
| 3050 |
\fi} |
| 3051 |
{\ifnum \HCol=4 \mtextfalse |
| 3052 |
\EndPauseMathClass|<end mtext space|>\Tg</\a:mathml mtext>\fi |
| 3053 |
\Tg</\a:mathml mtd>} |
| 3054 |
>>> |
| 3055 |
|
| 3056 |
|
| 3057 |
|
| 3058 |
|
| 3059 |
\<configure html-mml latex\><<< |
| 3060 |
|<config multicolumn|> |
| 3061 |
>>> |
| 3062 |
|
| 3063 |
|
| 3064 |
\<configure html-mml array\><<< |
| 3065 |
|<config multicolumn|> |
| 3066 |
>>> |
| 3067 |
|
| 3068 |
|
| 3069 |
\<config multicolumn\><<< |
| 3070 |
\Configure{multicolumn} |
| 3071 |
{\let\sv:VBorder\VBorder |
| 3072 |
\let\VBorder\empty |
| 3073 |
\Configure{VBorder}{}{}{}{}% |
| 3074 |
} |
| 3075 |
{\let\VBorder\sv:VBorder} |
| 3076 |
{\ifmmode \HCode{<\a:mathml mrow\Hnewline \mml:class="multicolumn}% |
| 3077 |
{|<attributes of mml multicolumn|>\HColAlign}\HCode{">}\else |
| 3078 |
\ifvmode\IgnorePar\fi |
| 3079 |
\HCode{<div class="multicolumn" }\HColAlign\HCode{>}\fi } |
| 3080 |
{\ifmmode \HCode{</\a:mathml mrow>}\else |
| 3081 |
\ifvmode\IgnorePar\fi \EndP\HCode{</div>}\fi } |
| 3082 |
\def\gob:sp#1{#1} |
| 3083 |
>>> |
| 3084 |
|
| 3085 |
\<attributes of mml multicolumn\><<< |
| 3086 |
\Configure{halignTD} {}{} |
| 3087 |
{<}{\HCode{-left}} |
| 3088 |
{-}{\HCode{-center}} |
| 3089 |
{>}{\HCode{-right}} |
| 3090 |
{p}{\HCode{-left}} |
| 3091 |
{}% |
| 3092 |
>>> |
| 3093 |
|
| 3094 |
|
| 3095 |
\<configure html-mml tex4ht\><<< |
| 3096 |
\Configure{halignTD} {}{} |
| 3097 |
{<}{\ifmathml \HCode{ \a:mathml columnalign="left"}\else |
| 3098 |
\HCode{ style="text-align:left; white-space:nowrap;"}\fi} |
| 3099 |
{-}{\ifmathml \HCode{ \a:mathml columnalign="center"}\else |
| 3100 |
\HCode{ style="text-align:center; white-space:nowrap;"}\fi} |
| 3101 |
{>}{\ifmathml \HCode{ \a:mathml columnalign="right"}\else |
| 3102 |
\HCode{ style="text-align:right; white-space:nowrap;"}\fi} |
| 3103 |
{^}{\ifmathml \HCode{ \a:mathml rowalign="top"}\else |
| 3104 |
\HCode{ style="vertical-align:top; white-space:nowrap;"}\fi} |
| 3105 |
{=}{\ifmathml \HCode{ \a:mathml rowalign="baseline"}\else |
| 3106 |
\HCode{ style="vertical-align:baseline; white-space:nowrap;"}\fi} |
| 3107 |
{||}{\ifmathml \HCode{ \a:mathml rowalign="center"}\else |
| 3108 |
\HCode{ style="vertical-align:middle; white-space:nowrap;"}\fi} |
| 3109 |
{_}{\ifmathml \HCode{ \a:mathml rowalign="bottom"}\else |
| 3110 |
\HCode{ style="vertical-align:bottom; white-space:nowrap;"}\fi} |
| 3111 |
{p}{\ifmathml \HCode{ \a:mathml columnalign="left"}\else |
| 3112 |
\HCode{ style="text-align:left;"}\fi} |
| 3113 |
{} |
| 3114 |
>>> |
| 3115 |
|
| 3116 |
|
| 3117 |
|
| 3118 |
|
| 3119 |
\<configure mathml tex4ht\><<< |
| 3120 |
\Configure{halignTD} {}{} |
| 3121 |
{<}{\HCode{ \a:mathml columnalign="left"}} |
| 3122 |
{-}{\HCode{ \a:mathml columnalign="center"}} |
| 3123 |
{>}{\HCode{ \a:mathml columnalign="right"}} |
| 3124 |
{^}{\HCode{ \a:mathml rowalign="top"}} |
| 3125 |
{=}{\HCode{ \a:mathml rowalign="baseline"}} |
| 3126 |
{||}{\HCode{ \a:mathml rowalign="center"}} |
| 3127 |
{_}{\HCode{ \a:mathml rowalign="bottom"}} |
| 3128 |
{p}{\HCode{ \a:mathml columnalign="left"}} |
| 3129 |
{} |
| 3130 |
>>> |
| 3131 |
|
| 3132 |
%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3133 |
\section{Big, BIG, ....} |
| 3134 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3135 |
|
| 3136 |
The |
| 3137 |
\verb'\special{t4ht@[}...\special{t4ht@]}' gobble the enclosed stuff. |
| 3138 |
The external pair is provided as grouping mechanism for |
| 3139 |
sub/super-scripts cases like \verb'\bigl(...\bigr)^x' within dvimath |
| 3140 |
mode. The \verb'{\HCode{}}' is neded for creating content delimiters |
| 3141 |
\verb'.' delimiters like in \verb'$\bigl. a_b \bigr)$'; without that mathml |
| 3142 |
gets something wrong there. |
| 3143 |
|
| 3144 |
|
| 3145 |
\begin{verbatim} |
| 3146 |
> There are some minor problems wit \bigl | corresponding to #x2223 in |
| 3147 |
> Mozilla encoding |
| 3148 |
> but I eliminted it by using \left | which turned to be a right solution. |
| 3149 |
|
| 3150 |
The \big... macros decide the dimensions of the delimiters. As is the |
| 3151 |
case with \sum, also here I don't know how to transport the dimensions |
| 3152 |
to mozilla. |
| 3153 |
|
| 3154 |
The \left...\right macros ask latex/mozilla to determine the |
| 3155 |
dimensions. |
| 3156 |
\end{verbatim} |
| 3157 |
|
| 3158 |
|
| 3159 |
|
| 3160 |
\</bigl, /bigr,... for mathml\><<< |
| 3161 |
\NewConfigure{Biggl}{2} |
| 3162 |
\NewConfigure{Biggm}{2} |
| 3163 |
\NewConfigure{Biggr}{2} |
| 3164 |
\NewConfigure{Bigl}{2} |
| 3165 |
\NewConfigure{Bigm}{2} |
| 3166 |
\NewConfigure{Bigr}{2} |
| 3167 |
\NewConfigure{biggl}{2} |
| 3168 |
\NewConfigure{biggm}{2} |
| 3169 |
\NewConfigure{biggr}{2} |
| 3170 |
\NewConfigure{bigl}{2} |
| 3171 |
\NewConfigure{bigm}{2} |
| 3172 |
\NewConfigure{bigr}{2} |
| 3173 |
|<big common|> |
| 3174 |
\:CheckOption{mathml-} \if:Option |
| 3175 |
|<big mathml-|> |
| 3176 |
\else |
| 3177 |
|<big mathml|> |
| 3178 |
\fi |
| 3179 |
>>> |
| 3180 |
|
| 3181 |
\<big mathml\><<< |
| 3182 |
\Configure{Biggl} |
| 3183 |
{\bgroup |
| 3184 |
\Configure{Bigg}{}{}{}{}% |
| 3185 |
\Configure{mathopen}{*} |
| 3186 |
{<mrow><mo \mml:class="MathClass-open" |
| 3187 |
fence="true" mathsize="2.45em" >} |
| 3188 |
{</mo><mrow>} |
| 3189 |
{\Configure{mathopen}{}{}{}{}}% |
| 3190 |
} |
| 3191 |
{\egroup} |
| 3192 |
\Configure{Biggr} |
| 3193 |
{\bgroup |
| 3194 |
\Configure{Bigg}{}{}{}{}% |
| 3195 |
\Configure{mathclose}{*} |
| 3196 |
{</mrow><mo \mml:class="MathClass-close" |
| 3197 |
fence="true" mathsize="2.45em" >} |
| 3198 |
{</mo></mrow>} |
| 3199 |
{\Configure{mathclose}{}{}{}{}}% |
| 3200 |
} |
| 3201 |
{\egroup} |
| 3202 |
\Configure{Bigl} |
| 3203 |
{\bgroup |
| 3204 |
\Configure{Big}{}{}{}{}% |
| 3205 |
\Configure{mathopen}{*} |
| 3206 |
{<mrow><mo \mml:class="MathClass-open" |
| 3207 |
fence="true" mathsize="1.61em" >} |
| 3208 |
{</mo><mrow>} |
| 3209 |
{\Configure{mathopen}{}{}{}{}}% |
| 3210 |
} |
| 3211 |
{\egroup} |
| 3212 |
\Configure{Bigr} |
| 3213 |
{\bgroup |
| 3214 |
\Configure{Big}{}{}{}{}% |
| 3215 |
\Configure{mathclose}{*} |
| 3216 |
{</mrow><mo \mml:class="MathClass-close" |
| 3217 |
fence="true" mathsize="1.61em" >} |
| 3218 |
{</mo></mrow>} |
| 3219 |
{\Configure{mathclose}{}{}{}{}}% |
| 3220 |
} |
| 3221 |
{\egroup} |
| 3222 |
\Configure{biggl} |
| 3223 |
{\bgroup |
| 3224 |
\Configure{bigg}{}{}{}{}% |
| 3225 |
\Configure{mathopen}{*} |
| 3226 |
{<mrow><mo \mml:class="MathClass-open" |
| 3227 |
fence="true" mathsize="2.03em" >} |
| 3228 |
{</mo><mrow>} |
| 3229 |
{\Configure{mathopen}{}{}{}{}}% |
| 3230 |
} |
| 3231 |
{\egroup} |
| 3232 |
\Configure{biggr} |
| 3233 |
{\bgroup |
| 3234 |
\Configure{bigg}{}{}{}{}% |
| 3235 |
\Configure{mathclose}{*} |
| 3236 |
{</mrow><mo \mml:class="MathClass-close" |
| 3237 |
fence="true" mathsize="2.03em" >} |
| 3238 |
{</mo></mrow>} |
| 3239 |
{\Configure{mathclose}{}{}{}{}}% |
| 3240 |
} |
| 3241 |
{\egroup} |
| 3242 |
\Configure{bigl} |
| 3243 |
{\bgroup |
| 3244 |
\Configure{big}{}{}{}{}% |
| 3245 |
\Configure{mathopen}{*} |
| 3246 |
{<mrow><mo \mml:class="MathClass-open" |
| 3247 |
fence="true" mathsize="1.19em" >} |
| 3248 |
{</mo><mrow>} |
| 3249 |
{\Configure{mathopen}{}{}{}{}}% |
| 3250 |
} |
| 3251 |
{\egroup} |
| 3252 |
\Configure{bigr} |
| 3253 |
{\bgroup |
| 3254 |
\Configure{big}{}{}{}{}% |
| 3255 |
\Configure{mathclose}{*} |
| 3256 |
{</mrow><mo \mml:class="MathClass-close" |
| 3257 |
fence="true" mathsize="1.19em" >} |
| 3258 |
{</mo></mrow>} |
| 3259 |
{\Configure{mathclose}{}{}{}{}}% |
| 3260 |
} |
| 3261 |
{\egroup} |
| 3262 |
>>> |
| 3263 |
|
| 3264 |
|
| 3265 |
|
| 3266 |
|
| 3267 |
\<big mathml-\><<< |
| 3268 |
\Configure{Biggl} |
| 3269 |
{\bgroup |
| 3270 |
\Configure{Bigg}{}{}{}{}% |
| 3271 |
\Configure{mathopen}{*} |
| 3272 |
{<mrow><mo \mml:class="MathClass-open" |
| 3273 |
fence="true" mathsize="2.45em" >} |
| 3274 |
{</mo>} |
| 3275 |
{\Configure{mathopen}{}{}{}{}}% |
| 3276 |
} |
| 3277 |
{\egroup} |
| 3278 |
\Configure{Biggr} |
| 3279 |
{\bgroup |
| 3280 |
\Configure{Bigg}{}{}{}{}% |
| 3281 |
\Configure{mathclose}{*} |
| 3282 |
{<mo \mml:class="MathClass-close" |
| 3283 |
fence="true" mathsize="2.45em" >} |
| 3284 |
{</mo></mrow>} |
| 3285 |
{\Configure{mathclose}{}{}{}{}}% |
| 3286 |
} |
| 3287 |
{\egroup} |
| 3288 |
\Configure{Bigl} |
| 3289 |
{\bgroup |
| 3290 |
\Configure{Big}{}{}{}{}% |
| 3291 |
\Configure{mathopen}{*} |
| 3292 |
{<mrow><mo \mml:class="MathClass-open" |
| 3293 |
fence="true" mathsize="1.61em" >} |
| 3294 |
{</mo>} |
| 3295 |
{\Configure{mathopen}{}{}{}{}}% |
| 3296 |
} |
| 3297 |
{\egroup} |
| 3298 |
\Configure{Bigr} |
| 3299 |
{\bgroup |
| 3300 |
\Configure{Big}{}{}{}{}% |
| 3301 |
\Configure{mathclose}{*} |
| 3302 |
{<mo \mml:class="MathClass-close" |
| 3303 |
fence="true" mathsize="1.61em" >} |
| 3304 |
{</mo></mrow>} |
| 3305 |
{\Configure{mathclose}{}{}{}{}}% |
| 3306 |
} |
| 3307 |
{\egroup} |
| 3308 |
\Configure{biggl} |
| 3309 |
{\bgroup |
| 3310 |
\Configure{bigg}{}{}{}{}% |
| 3311 |
\Configure{mathopen}{*} |
| 3312 |
{<mrow><mo \mml:class="MathClass-open" |
| 3313 |
fence="true" mathsize="2.03em" >} |
| 3314 |
{</mo>} |
| 3315 |
{\Configure{mathopen}{}{}{}{}}% |
| 3316 |
} |
| 3317 |
{\egroup} |
| 3318 |
\Configure{biggr} |
| 3319 |
{\bgroup |
| 3320 |
\Configure{bigg}{}{}{}{}% |
| 3321 |
\Configure{mathclose}{*} |
| 3322 |
{<mo \mml:class="MathClass-close" |
| 3323 |
fence="true" mathsize="2.03em" >} |
| 3324 |
{</mo></mrow>} |
| 3325 |
{\Configure{mathclose}{}{}{}{}}% |
| 3326 |
} |
| 3327 |
{\egroup} |
| 3328 |
\Configure{bigl} |
| 3329 |
{\bgroup |
| 3330 |
\Configure{big}{}{}{}{}% |
| 3331 |
\Configure{mathopen}{*} |
| 3332 |
{<mrow><mo \mml:class="MathClass-open" |
| 3333 |
fence="true" mathsize="1.19em" >} |
| 3334 |
{</mo>} |
| 3335 |
{\Configure{mathopen}{}{}{}{}}% |
| 3336 |
} |
| 3337 |
{\egroup} |
| 3338 |
\Configure{bigr} |
| 3339 |
{\bgroup |
| 3340 |
\Configure{big}{}{}{}{}% |
| 3341 |
\Configure{mathclose}{*} |
| 3342 |
{<mo \mml:class="MathClass-close" |
| 3343 |
fence="true" mathsize="1.19em" >} |
| 3344 |
{</mo></mrow>} |
| 3345 |
{\Configure{mathclose}{}{}{}{}}% |
| 3346 |
} |
| 3347 |
{\egroup} |
| 3348 |
>>> |
| 3349 |
|
| 3350 |
|
| 3351 |
|
| 3352 |
\<big common\><<< |
| 3353 |
\Configure{Biggm} |
| 3354 |
{\bgroup |
| 3355 |
\Configure{Bigg}{}{}{}{}% |
| 3356 |
\Configure{mathrel}{*} |
| 3357 |
{<mo \mml:class="MathClass-rel" |
| 3358 |
fence="true" mathsize="2.45em" >} |
| 3359 |
{</mo>} |
| 3360 |
{\Configure{mathrel}{}{}{}{}}% |
| 3361 |
} |
| 3362 |
{\egroup} |
| 3363 |
\Configure{Bigm} |
| 3364 |
{\bgroup |
| 3365 |
\Configure{Big}{}{}{}{}% |
| 3366 |
\Configure{mathrel}{*} |
| 3367 |
{<mo \mml:class="MathClass-rel" |
| 3368 |
fence="true" mathsize="1.61em" >} |
| 3369 |
{</mo>} |
| 3370 |
{\Configure{mathrel}{}{}{}{}}% |
| 3371 |
} |
| 3372 |
{\egroup} |
| 3373 |
\Configure{biggm} |
| 3374 |
{\bgroup |
| 3375 |
\Configure{bigg}{}{}{}{}% |
| 3376 |
\Configure{mathrel}{*} |
| 3377 |
{<mo \mml:class="MathClass-rel" |
| 3378 |
fence="true" mathsize="2.03em" >} |
| 3379 |
{</mo>} |
| 3380 |
{\Configure{mathrel}{}{}{}{}}% |
| 3381 |
} |
| 3382 |
{\egroup} |
| 3383 |
\Configure{bigm} |
| 3384 |
{\bgroup |
| 3385 |
\Configure{big}{}{}{}{}% |
| 3386 |
\Configure{mathrel}{*} |
| 3387 |
{<mo \mml:class="MathClass-rel" |
| 3388 |
fence="true" mathsize="1.19em" >} |
| 3389 |
{</mo>} |
| 3390 |
{\Configure{mathrel}{}{}{}{}}% |
| 3391 |
} |
| 3392 |
{\egroup} |
| 3393 |
>>> |
| 3394 |
|
| 3395 |
|
| 3396 |
|
| 3397 |
\</bigl, /bigr,... for mathml\><<< |
| 3398 |
\def\:tempc#1{\ht:special{t4ht@[}(\ht:special{t4ht@]}% |
| 3399 |
\a:bigl\mathopen{\left:right\big{#1\:EMPTY}}\b:bigl\:EMPTY} |
| 3400 |
\HLet\bigl=\:tempc |
| 3401 |
\def\:tempc#1{\a:bigm\mathrel{\left:right\big{#1\:EMPTY}}\b:bigm} |
| 3402 |
\HLet\bigm=\:tempc |
| 3403 |
\def\:tempc#1{\:EMPTY |
| 3404 |
\a:bigr\mathclose{\left:right\big{#1\:EMPTY}}\b:bigr% |
| 3405 |
\ht:special{t4ht@[})\ht:special{t4ht@]}} |
| 3406 |
\HLet\bigr=\:tempc |
| 3407 |
\def\:tempc#1{\ht:special{t4ht@[}(\ht:special{t4ht@]}% |
| 3408 |
\a:Bigl\mathopen{\left:right\Big{#1}\:EMPTY}\b:Bigl\:EMPTY} |
| 3409 |
\HLet\Bigl=\:tempc |
| 3410 |
\def\:tempc#1{\a:Bigm\mathrel{\left:right\Big{#1\:EMPTY}}\b:Bigm} |
| 3411 |
\HLet\Bigm=\:tempc |
| 3412 |
\def\:tempc#1{\:EMPTY |
| 3413 |
\a:Bigr\mathclose{\left:right\Big{#1\:EMPTY}}\b:Bigr% |
| 3414 |
\ht:special{t4ht@[})\ht:special{t4ht@]}} |
| 3415 |
\HLet\Bigr=\:tempc |
| 3416 |
\def\:tempc#1{\ht:special{t4ht@[}(\ht:special{t4ht@]}% |
| 3417 |
\a:biggl\mathopen{\left:right\bigg{#1\:EMPTY}}\b:biggl\:EMPTY} |
| 3418 |
\HLet\biggl=\:tempc |
| 3419 |
\def\:tempc#1{\a:biggm\mathrel{\left:right\bigg{#1\:EMPTY}}\b:biggm} |
| 3420 |
\HLet\biggm=\:tempc |
| 3421 |
\def\:tempc#1{\:EMPTY |
| 3422 |
\a:biggr\mathclose{\left:right\bigg{#1\:EMPTY}}\b:biggr% |
| 3423 |
\ht:special{t4ht@[})\ht:special{t4ht@]}} |
| 3424 |
\HLet\biggr=\:tempc |
| 3425 |
\def\:tempc#1{\ht:special{t4ht@[}(\ht:special{t4ht@]}% |
| 3426 |
\a:Biggl\mathopen{\left:right\Bigg{#1\:EMPTY}}\b:Biggl\:EMPTY} |
| 3427 |
\HLet\Biggl=\:tempc |
| 3428 |
\def\:tempc#1{\a:Biggm\mathrel{\left:right\Bigg{#1\:EMPTY}}\b:Biggm} |
| 3429 |
\HLet\Biggm=\:tempc |
| 3430 |
\def\:tempc#1{\:EMPTY |
| 3431 |
\a:Biggr\mathclose{\left:right\Bigg{#1}\:EMPTY}\b:Biggr |
| 3432 |
\ht:special{t4ht@[})\ht:special{t4ht@]}} |
| 3433 |
\HLet\Biggr=\:tempc |
| 3434 |
\def\:EMPTY{{\HCode{}}} |
| 3435 |
\def\left:right{% |
| 3436 |
\let\left|=\o:left: |
| 3437 |
\let\right|=\o:right: |
| 3438 |
\Configure{left}{}{}\Configure{right}{}{}} |
| 3439 |
>>> |
| 3440 |
|
| 3441 |
\verb+\bigl{.}+ et al produce empty para,etr , hence the \verb+\:EMPTY+ is a ompensation for such cases. |
| 3442 |
|
| 3443 |
\<mathml plain,fontmath\><<< |
| 3444 |
\Configure{big} |
| 3445 |
{}{} |
| 3446 |
{\HCode{<\a:mathml mstyle mathsize="1.19em">}} |
| 3447 |
{\HCode{</\a:mathml mstyle>}} |
| 3448 |
\Configure{Big} |
| 3449 |
{}{} |
| 3450 |
{\HCode{<\a:mathml mstyle mathsize="1.61em">}} |
| 3451 |
{\HCode{</\a:mathml mstyle>}} |
| 3452 |
\Configure{bigg} |
| 3453 |
{}{} |
| 3454 |
{\HCode{<\a:mathml mstyle mathsize="2.03em">}} |
| 3455 |
{\HCode{</\a:mathml mstyle>}} |
| 3456 |
\Configure{Bigg} |
| 3457 |
{}{} |
| 3458 |
{\HCode{<\a:mathml mstyle mathsize="2.45em">}} |
| 3459 |
{\HCode{</\a:mathml mstyle>}} |
| 3460 |
>>> |
| 3461 |
|
| 3462 |
% \R=8.5; \R*1.4; \WriteVal\R |
| 3463 |
% \R=11.5; \R*1.4; \WriteVal\R |
| 3464 |
% \R=14.5; \R*1.4; \WriteVal\R |
| 3465 |
% \R=17.5; \R*1.4; \WriteVal\R |
| 3466 |
|
| 3467 |
|
| 3468 |
\<mathml plain,fontmath\><<< |
| 3469 |
\def\:tempc#1{{\hbox{\a:big$\c:big |
| 3470 |
\left#1\hbox{}\right.\n@space\d:big$\b:big}}} |
| 3471 |
\HLet\big=\:tempc |
| 3472 |
\def\:tempc#1{{\hbox{\a:Big$\c:Big |
| 3473 |
\left#1\hbox{}\right.\n@space\d:Big$\b:Big}}} |
| 3474 |
\HLet\Big=\:tempc |
| 3475 |
\def\:tempc#1{{\hbox{\a:bigg$\c:bigg |
| 3476 |
\left#1\hbox{}\right.\n@space\d:bigg$\b:bigg}}} |
| 3477 |
\HLet\bigg=\:tempc |
| 3478 |
\def\:tempc#1{{\hbox{\a:Bigg$\c:Bigg |
| 3479 |
\left#1\hbox{}\right.\n@space\d:Bigg$\b:Bigg}}} |
| 3480 |
\HLet\Bigg=\:tempc |
| 3481 |
>>> |
| 3482 |
|
| 3483 |
\<configure mathml amsbsy\><<< |
| 3484 |
\Configure{pmb} |
| 3485 |
{\ifmmode \HCode{<!--binary math rel, tripple hight-->}\fi} |
| 3486 |
{\ifmmode \HCode{<!--/binary math rel, tripple hight-->}\fi} |
| 3487 |
>>> |
| 3488 |
|
| 3489 |
|
| 3490 |
|
| 3491 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3492 |
\section{stackrel} |
| 3493 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3494 |
|
| 3495 |
\<mathml latex\><<< |
| 3496 |
\def\:temp#1#2{{\a:stackrel{#1}\b:stackrel {#2}\c:stackrel}} |
| 3497 |
\HLet\stackrel|=\:temp |
| 3498 |
\:CheckOption{stackrel-} \if:Option |
| 3499 |
\Configure{stackrel} |
| 3500 |
{\mathrel\bgroup \HCode{<\a:mathml mglyph\Hnewline |
| 3501 |
alt="\string\stackrel}\afterassignment\put:arg\tmp:toks} |
| 3502 |
{\afterassignment\put:arg\tmp:toks} |
| 3503 |
{\HCode{" />}\egroup} |
| 3504 |
\def\put:arg{\HCode{{\the\tmp:toks}}} |
| 3505 |
\else |
| 3506 |
\Configure{stackrel} |
| 3507 |
{\HCode{<\a:mathml mover\Hnewline |
| 3508 |
\mml:class="stackrel"><\a:mathml mrow\Hnewline>}\inv:i:iii} |
| 3509 |
{\HCode{</\a:mathml mrow><\a:mathml |
| 3510 |
mrow\Hnewline>}|<mathop nested within stackrel|>\mathop} |
| 3511 |
{\HCode{</\a:mathml mrow></\a:mathml mover>}} |
| 3512 |
\def\inv:i:iii#1#2#3{{#3}#2{#1}} |
| 3513 |
\fi |
| 3514 |
>>> |
| 3515 |
|
| 3516 |
\<mathop nested within stackrel\><<< |
| 3517 |
\Configure{mathop*}{*} |
| 3518 |
{<\a:mathml mrow>} |
| 3519 |
{</\a:mathml mrow>} |
| 3520 |
{\Configure{mathop}{}{}{}{}}% |
| 3521 |
>>> |
| 3522 |
|
| 3523 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3524 |
\subsection{fontmath.ltx} |
| 3525 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3526 |
|
| 3527 |
|
| 3528 |
Accent versus underscript: \verb=\underbrace{x+y+z}= |
| 3529 |
versus \verb=\underbrace{\strut x+y+z}= |
| 3530 |
|
| 3531 |
\<mathml plain,fontmath\><<< |
| 3532 |
\Configure{overbrace} |
| 3533 |
{\Configure{mathop*}{*} |
| 3534 |
{<\a:mathml mover \a:mathml accent="false"><\a:mathml mrow>} |
| 3535 |
{</\a:mathml mrow><\a:mathml mo>\string |
| 3536 |
&\#xFE37;</\a:mathml mo></\a:mathml mover>} |
| 3537 |
{\Configure{mathop}{}{}{}{}}% |
| 3538 |
} |
| 3539 |
{\let\o:overbrace:=\displaystyle} |
| 3540 |
{} |
| 3541 |
\Configure{underbrace} |
| 3542 |
{\Configure{mathop*}{*} |
| 3543 |
{<\a:mathml munder |
| 3544 |
\a:mathml accentunder="false"><\a:mathml mrow>} |
| 3545 |
{</\a:mathml mrow><\a:mathml mo>\string |
| 3546 |
&\#x23DF;</\a:mathml mo></\a:mathml munder>} |
| 3547 |
{\Configure{mathop}{}{}{}{}}% |
| 3548 |
} |
| 3549 |
{\let\o:underbrace:=\displaystyle} |
| 3550 |
{} |
| 3551 |
>>> |
| 3552 |
|
| 3553 |
\<\><<< |
| 3554 |
\def\:temp#1{% |
| 3555 |
\Configure{mathop*}{*}{<\a:mathml mrow \mml:class="underbrace">} |
| 3556 |
{</\a:mathml mrow>}% |
| 3557 |
{\Configure{mathop}{}{}{}{}}% |
| 3558 |
\mathop{\hbox{$\displaystyle{#1}$}}\limits} |
| 3559 |
\HLet\underbrace|=\:temp |
| 3560 |
\def\:temp#1{% |
| 3561 |
\Configure{mathop*}{*}{<\a:mathml mrow \mml:class="overbrace">} |
| 3562 |
{</\a:mathml mrow>}% |
| 3563 |
{\Configure{mathop}{}{}{}{}}% |
| 3564 |
\mathop{\hbox{$\displaystyle{#1}$}}\limits} |
| 3565 |
\HLet\overbrace|=\:temp |
| 3566 |
>>> |
| 3567 |
|
| 3568 |
|
| 3569 |
\<amsmath mathmlNO\><<< |
| 3570 |
\def\:temp#1{% |
| 3571 |
\Configure{mathop*}{*}{<\a:mathml mrow \mml:class="underbrace">} |
| 3572 |
{</\a:mathml mrow>}% |
| 3573 |
{\Configure{mathop}{}{}{}{}}% |
| 3574 |
\mathop{\vtop{$\displaystyle{#1}$}}\limits} |
| 3575 |
\HLet\underbrace|=\:temp |
| 3576 |
>>> |
| 3577 |
|
| 3578 |
\<mathml plain,fontmath\><<< |
| 3579 |
\Configure{MathClass}{0}{*}{<\a:mathml mi\Hnewline>}{</\a:mathml mi>}{} |
| 3580 |
\Configure{MathClass}{1}{*}{<\a:mathml mi\Hnewline |
| 3581 |
\mml:class="MathClass-op">}{</\a:mathml mi><\a:mathml mo> &\#x2061;<!--FUNCTION APPLICATION--></\a:mathml mo>}{} |
| 3582 |
\Configure{MathClass}{2}{*}{<\a:mathml mo\Hnewline |
| 3583 |
\mml:class="MathClass-bin" \a:mathml stretchy="false">}{</\a:mathml mo>}{} |
| 3584 |
\Configure{MathClass}{3}{*}{<\a:mathml mo\Hnewline |
| 3585 |
\mml:class="MathClass-rel" \a:mathml stretchy="false">}{</\a:mathml mo>}{} |
| 3586 |
\Configure{MathClass}{4}{*}{<\a:mathml mo\Hnewline |
| 3587 |
\mml:class="MathClass-open" \a:mathml stretchy="false">} |
| 3588 |
{</\a:mathml mo>}{} |
| 3589 |
\Configure{MathClass}{5}{*}{<\a:mathml mo\Hnewline |
| 3590 |
\mml:class="MathClass-close" \a:mathml stretchy="false">} |
| 3591 |
{</\a:mathml mo>}{} |
| 3592 |
\Configure{MathClass}{6}{*}{<\a:mathml mo\Hnewline |
| 3593 |
\mml:class="MathClass-punc" \a:mathml stretchy="false">}{</\a:mathml mo>}{} |
| 3594 |
\Configure{MathClass}{7}{*}{<\a:mathml mn>}{</\a:mathml mn>} |
| 3595 |
{0123456789} |
| 3596 |
\ifx \mathordMathClass\:UnDef |
| 3597 |
\NewMathClass\mathordMathClass |
| 3598 |
\fi |
| 3599 |
\Configure{MathClass}{\mathordMathClass}{*}{<\a:mathml mo\Hnewline |
| 3600 |
\mml:class="MathClass-ord">}{</\a:mathml mo>}{} |
| 3601 |
\Configure{FormulaClass}{0}{}{}{} |
| 3602 |
\Configure{FormulaClass}{1}{}{}{} |
| 3603 |
\Configure{FormulaClass}{2}{}{}{} |
| 3604 |
\Configure{FormulaClass}{3}{}{}{} |
| 3605 |
\Configure{FormulaClass}{4}{}{}{} |
| 3606 |
\Configure{FormulaClass}{5}{}{}{} |
| 3607 |
\Configure{FormulaClass}{6}{}{}{} |
| 3608 |
>>> |
| 3609 |
|
| 3610 |
|
| 3611 |
The following code is to insert spaces |
| 3612 |
for casses like \verb=$a \mathop{div} b$= |
| 3613 |
but not \verb=$\mathop{div} (\mathbf{F})$= |
| 3614 |
|
| 3615 |
\<mathml plain,fontmath\><<< |
| 3616 |
\Css{mo.MathClass-op + mi{margin-left:0.3em}} |
| 3617 |
\Css{mi + mo.MathClass-op{margin-left:0.3em}} |
| 3618 |
>>> |
| 3619 |
|
| 3620 |
|
| 3621 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3622 |
\section{Accessibility} |
| 3623 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3624 |
|
| 3625 |
MathML core specification provides a new way to specify |
| 3626 |
an accessible description of mathematical expressions, using the |
| 3627 |
\Link[https://w3c.github.io/mathml-docs/intent-explainer/]{}{}intent attribute\EndLink. |
| 3628 |
\LaTeX{} will provide commands to set the intent attribute for |
| 3629 |
mathematical expressions. We can redefine these commands |
| 3630 |
to insert the necessary attributes in the MathML output. |
| 3631 |
|
| 3632 |
\<mathml latex\><<< |
| 3633 |
\ifdefined\MathMLintent |
| 3634 |
\RenewDocumentCommand{\MathMLintent}{mm}{{% |
| 3635 |
\def\${$}% Fix support for the \$ command |
| 3636 |
\HCode{<mrow intent="#1">}#2\HCode{</mrow>}% |
| 3637 |
}} |
| 3638 |
\fi |
| 3639 |
|
| 3640 |
\ifdefined\MathMLarg |
| 3641 |
\RenewDocumentCommand\MathMLarg{mm}{% |
| 3642 |
\HCode{<mrow arg="#1">}#2\HCode{</mrow>}% |
| 3643 |
} |
| 3644 |
\fi |
| 3645 |
>>> |
| 3646 |
|
| 3647 |
|
| 3648 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3649 |
\section{Limits of Sub- snd Super- Scripts} |
| 3650 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3651 |
|
| 3652 |
|
| 3653 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3654 |
\subsection{Outline} |
| 3655 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3656 |
|
| 3657 |
|
| 3658 |
\<limits sub, sup, subsup\><<< |
| 3659 |
\Configure{nolimits}{\HCode{<!--nolimits-->}} |
| 3660 |
\Configure{limits} |
| 3661 |
{|<limit scripts|>} |
| 3662 |
>>> |
| 3663 |
|
| 3664 |
|
| 3665 |
\<limit scripts\><<< |
| 3666 |
\let|<restore SUB|>=\:UnDef |
| 3667 |
\let|<restore SUP|>=\:UnDef |
| 3668 |
\ifx \:temp\sp |<conf limits SUP|>\else |
| 3669 |
\ifx \:temp\sb |<conf limits SUB|>\fi |
| 3670 |
\fi |
| 3671 |
|<conf limits SUBSUP|>% |
| 3672 |
>>> |
| 3673 |
|
| 3674 |
|
| 3675 |
|
| 3676 |
\<limits sub, sup, subsup\><<< |
| 3677 |
\Configure{displaylimits} |
| 3678 |
{\ifDisplayMath \expandafter\disp:limits\fi} |
| 3679 |
\def\disp:limits{|<limit scripts|>} |
| 3680 |
>>> |
| 3681 |
|
| 3682 |
|
| 3683 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3684 |
\subsection{Simultaneously Sub- and Super- Scripts} |
| 3685 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3686 |
|
| 3687 |
|
| 3688 |
\<conf limits SUBSUP\><<< |
| 3689 |
|<save pre-limits SUBSUP|>% |
| 3690 |
\Configure{SUBSUP} |
| 3691 |
{\ifx |<restore SUB|>\:UnDef\else |<restore SUB|>\fi |
| 3692 |
\ifx |<restore SUP|>\:UnDef\else |<restore SUP|>\fi |
| 3693 |
|<restore pre-limits SUBSUP|>% |
| 3694 |
\Send{BACK} |
| 3695 |
{<\a:mathml munderover \a:mathml accentunder="false" |
| 3696 |
\a:mathml accent="false"><\a:mathml mrow |
| 3697 |
\Hnewline>}% |
| 3698 |
\Tg</\a:mathml mrow>\Tg<\a:mathml |
| 3699 |
mrow\Hnewline>\trap:base |
| 3700 |
} |
| 3701 |
{\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>\trap:base} |
| 3702 |
{\Tg</\a:mathml mrow>\TG</\a:mathml munderover\Hnewline>} |
| 3703 |
>>> |
| 3704 |
|
| 3705 |
|
| 3706 |
\<save pre-limits SUBSUP\><<< |
| 3707 |
\let|<restore SUBSUP|>=\SUBSUP: |
| 3708 |
>>> |
| 3709 |
|
| 3710 |
\<restore pre-limits SUBSUP\><<< |
| 3711 |
\ifx |<restore SUBSUP|>\:UnDef \else |
| 3712 |
\let\SUBSUP:=|<restore SUBSUP|>% |
| 3713 |
\fi |
| 3714 |
>>> |
| 3715 |
|
| 3716 |
\<limits sub, sup, subsup\><<< |
| 3717 |
\ifx \a:putSUB\:UnDef \else |
| 3718 |
\pend:def\a:putSUB{\ifx |<restore SUBSUP|>\:UnDef\else |
| 3719 |
\let\SUBSUP:=|<restore SUBSUP|>% |
| 3720 |
\let|<restore SUBSUP|>=\:UnDef |
| 3721 |
\fi}% |
| 3722 |
\fi |
| 3723 |
\ifx \a:putSUP\:UnDef \else |
| 3724 |
\pend:def\a:putSUP{\ifx |<restore SUBSUP|>\:UnDef\else |
| 3725 |
\let\SUBSUP:=|<restore SUBSUP|>% |
| 3726 |
\let|<restore SUBSUP|>=\:UnDef |
| 3727 |
\fi}% |
| 3728 |
\fi |
| 3729 |
>>> |
| 3730 |
|
| 3731 |
|
| 3732 |
\<restore SUBSUP\><<< |
| 3733 |
\pl:SUBSUP |
| 3734 |
>>> |
| 3735 |
|
| 3736 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3737 |
\subsection{Superscripts} |
| 3738 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3739 |
|
| 3740 |
|
| 3741 |
|
| 3742 |
\<conf limits SUP\><<< |
| 3743 |
|<save pre-limits SUP|>% |
| 3744 |
\Configure{SUP} |
| 3745 |
{|<open external limits SUP|>\bgroup |
| 3746 |
|<restore pre-limits SUBSUP|>% |
| 3747 |
|<conf second limits SUP|>\trap:base} |
| 3748 |
{}% |
| 3749 |
>>> |
| 3750 |
|
| 3751 |
\<save pre-limits SUP\><<< |
| 3752 |
\def\pl:SUP{\Configure{SUP}}% |
| 3753 |
\expandafter\append:def |
| 3754 |
\expandafter\pl:SUP\expandafter{\expandafter{\a:SUP}}% |
| 3755 |
\expandafter\append:def |
| 3756 |
\expandafter\pl:SUP\expandafter{\expandafter{\b:SUP}}% |
| 3757 |
>>> |
| 3758 |
|
| 3759 |
\<conf second limits SUP\><<< |
| 3760 |
\Configure{SUP} |
| 3761 |
{|<open intermediate limits SUP|>\bgroup |
| 3762 |
|<conf third limit SUP|>\trap:base} |
| 3763 |
{\egroup|<close external limits SUP|>}% |
| 3764 |
>>> |
| 3765 |
|
| 3766 |
|
| 3767 |
\<conf third limit SUP\><<< |
| 3768 |
\Configure{SUP} |
| 3769 |
{|<open internal limits SUP|>\bgroup \trap:base} |
| 3770 |
{\egroup |<close internal limits SUP|>}% |
| 3771 |
>>> |
| 3772 |
|
| 3773 |
|
| 3774 |
\<open external limits SUP\><<< |
| 3775 |
\Send{BACK}{<\a:mathml mover |
| 3776 |
\mml:class="msup"><\a:mathml mrow\Hnewline>}% |
| 3777 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3778 |
>>> |
| 3779 |
|
| 3780 |
\<close external limits SUP\><<< |
| 3781 |
\Tg</\a:mathml mrow>\TG</\a:mathml mover\Hnewline>\aftergroup|<restore SUP|>% |
| 3782 |
>>> |
| 3783 |
|
| 3784 |
\<restore SUP\><<< |
| 3785 |
\pl:SUP >>> |
| 3786 |
|
| 3787 |
\<open intermediate limits SUP\><<< |
| 3788 |
\Send{BACK}{<\a:mathml msup><\a:mathml mrow\Hnewline>}% |
| 3789 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3790 |
>>> |
| 3791 |
|
| 3792 |
\<open internal limits SUP\><<< |
| 3793 |
\Send{BACK}{<\a:mathml msup><\a:mathml mrow\Hnewline>}% |
| 3794 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3795 |
>>> |
| 3796 |
|
| 3797 |
\<close internal limits SUP\><<< |
| 3798 |
\Tg</\a:mathml mrow>\TG</\a:mathml msup\Hnewline>% |
| 3799 |
>>> |
| 3800 |
|
| 3801 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3802 |
\subsection{Subscripts} |
| 3803 |
%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3804 |
|
| 3805 |
|
| 3806 |
|
| 3807 |
|
| 3808 |
|
| 3809 |
\<conf limits SUB\><<< |
| 3810 |
|<save pre-limits SUB|>% |
| 3811 |
\Configure{SUB} |
| 3812 |
{|<open external limits SUB|>\bgroup |
| 3813 |
|<restore pre-limits SUBSUP|>% |
| 3814 |
|<conf second limits SUB|>\trap:base} |
| 3815 |
{}% |
| 3816 |
>>> |
| 3817 |
|
| 3818 |
\<save pre-limits SUB\><<< |
| 3819 |
\def\pl:SUB{\Configure{SUB}}% |
| 3820 |
\expandafter\append:def |
| 3821 |
\expandafter\pl:SUB\expandafter{\expandafter{\a:SUB}}% |
| 3822 |
\expandafter\append:def |
| 3823 |
\expandafter\pl:SUB\expandafter{\expandafter{\b:SUB}}% |
| 3824 |
>>> |
| 3825 |
|
| 3826 |
\<conf second limits SUB\><<< |
| 3827 |
\Configure{SUB} |
| 3828 |
{|<open intermediate limits SUB|>\bgroup |
| 3829 |
|<conf third limit SUB|>\trap:base} |
| 3830 |
{\egroup|<close external limits SUB|>}% |
| 3831 |
>>> |
| 3832 |
|
| 3833 |
|
| 3834 |
\<conf third limit SUB\><<< |
| 3835 |
\Configure{SUB} |
| 3836 |
{|<open internal limits SUB|>\bgroup \trap:base} |
| 3837 |
{\egroup |<close internal limits SUB|>}% |
| 3838 |
>>> |
| 3839 |
|
| 3840 |
|
| 3841 |
\<open external limits SUB\><<< |
| 3842 |
\Send{BACK}{<\a:mathml munder |
| 3843 |
\mml:class="msub"><\a:mathml mrow\Hnewline>}% |
| 3844 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3845 |
>>> |
| 3846 |
|
| 3847 |
\<close external limits SUB\><<< |
| 3848 |
\Tg</\a:mathml mrow>\TG</\a:mathml |
| 3849 |
munder\Hnewline>\aftergroup|<restore SUB|>% |
| 3850 |
>>> |
| 3851 |
|
| 3852 |
\<restore SUB\><<< |
| 3853 |
\pl:SUB >>> |
| 3854 |
|
| 3855 |
\<open intermediate limits SUB\><<< |
| 3856 |
\Send{BACK}{<\a:mathml msub><\a:mathml mrow\Hnewline>}% |
| 3857 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3858 |
>>> |
| 3859 |
|
| 3860 |
\<open internal limits SUB\><<< |
| 3861 |
\Send{BACK}{<\a:mathml msub><\a:mathml mrow\Hnewline>}% |
| 3862 |
\Tg</\a:mathml mrow>\Tg<\a:mathml mrow\Hnewline>% |
| 3863 |
>>> |
| 3864 |
|
| 3865 |
\<close internal limits SUB\><<< |
| 3866 |
\Tg</\a:mathml mrow>\TG</\a:mathml msub\Hnewline>% |
| 3867 |
>>> |
| 3868 |
|
| 3869 |
%%%%%%%%%%%%% |
| 3870 |
\subsection{Limits on Operators} |
| 3871 |
%%%%%%%%%%%%% |
| 3872 |
|
| 3873 |
|
| 3874 |
\<configure mathml latex\><<< |
| 3875 |
\def\:tempb#1{% |
| 3876 |
\expandafter\let\expandafter\:tempc\csname #1\endcsname |
| 3877 |
\append:def\:tempc{\limits}% |
| 3878 |
\expandafter\HLet\csname #1\endcsname\:tempc |
| 3879 |
} |
| 3880 |
\:tempb{lim} |
| 3881 |
% \:tempb{limsup} |
| 3882 |
% \:tempb{liminf} |
| 3883 |
\:tempb{max} |
| 3884 |
\:tempb{min} |
| 3885 |
\:tempb{sup} |
| 3886 |
\:tempb{inf} |
| 3887 |
\:tempb{det} |
| 3888 |
\:tempb{Pr} |
| 3889 |
\:tempb{gcd} |
| 3890 |
|
| 3891 |
|
| 3892 |
>>> |
| 3893 |
|
| 3894 |
We need a special configuration for these two word operators, in order to get a good spacing. |
| 3895 |
|
| 3896 |
\<configure mathml latex\><<< |
| 3897 |
\def\:limspaces#1#2{\HCode{<\a:mathml mi>#1</\a:mathml mi><\a:mathml mspace class="thinspace" width="0.17em"></\a:mathml mspace><\a:mathml mi>#2</\a:mathml mi><\a:mathml mspace class="thinspace" width="0.17em"></\a:mathml mspace>}} |
| 3898 |
\def\:tempa{\mathop{\:limspaces{lim}{sup}}\limits} |
| 3899 |
\HLet\limsup\:tempa |
| 3900 |
\def\:tempa{\mathop{\:limspaces{lim}{inf}}\limits} |
| 3901 |
\HLet\liminf\:tempa |
| 3902 |
>>> |
| 3903 |
|
| 3904 |
%%%%%%%%%%%%%%% |
| 3905 |
\subsection{Upright letters} |
| 3906 |
%%%%%%%%%%%%%%% |
| 3907 |
|
| 3908 |
The following commands should produce upright characters. So we redefine them |
| 3909 |
to produce mi elements with mathvariant attribute, that hold their Unicode |
| 3910 |
charactes. |
| 3911 |
|
| 3912 |
Extra brackets are used in order to support subscripts and superscripts. |
| 3913 |
|
| 3914 |
\<configure mathml latex\><<< |
| 3915 |
\def\:temp#1#2{\def\:tempa{\PauseMathClass{\HCode{<mi mathvariant="normal">}\ht:special{t4ht@+\string&{35}x#2{59}}\a:HChar\HCode{</mi>}}\EndPauseMathClass}\HLet#1\:tempa} |
| 3916 |
\:temp\Gamma{0393} |
| 3917 |
\:temp\Delta{0394} |
| 3918 |
\:temp\Theta{0398} |
| 3919 |
\:temp\Lambda{039B} |
| 3920 |
\:temp\Xi{039E} |
| 3921 |
\:temp\Pi{03A0} |
| 3922 |
\:temp\Sigma{03A3} |
| 3923 |
\:temp\Upsilon{03A5} |
| 3924 |
\:temp\Phi{03A6} |
| 3925 |
\:temp\Psi{03A8} |
| 3926 |
\:temp\Omega{03A9} |
| 3927 |
|
| 3928 |
>>> |
| 3929 |
|
| 3930 |
|
| 3931 |
|
| 3932 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3933 |
\section{Sized Operations} |
| 3934 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 3935 |
|
| 3936 |
This code tries to prevent discarding of math formatting inside of |
| 3937 |
mathop. See \Link{https://tug.org/pipermail/tex4ht/2016q4/001631.html}{}this bug report\EndLink. |
| 3938 |
|
| 3939 |
I use AtBeginDocument because it doesn't seem to have any effect otherwise. The code comes |
| 3940 |
from tex4ht-info.tex. |
| 3941 |
|
| 3942 |
\<configure mathml latex\><<< |
| 3943 |
\AtBeginDocument{% |
| 3944 |
\Configure{mathop*}{*}{}{}{\Configure{mathop}{*}{<\a:mathml mo>}{</\a:mathml mo>}{}} |
| 3945 |
} |
| 3946 |
>>> |
| 3947 |
|
| 3948 |
|
| 3949 |
\<plain,latex mathml\><<< |
| 3950 |
\def\mathop:prefix#1{% |
| 3951 |
\Configure{mathop}{*}{<\a:mathml mo #1\Hnewline>}{</\a:mathml mo>}% |
| 3952 |
{\Configure{mathop}{*}{<\a:mathml mo>}{</\a:mathml mo>}{}}} |
| 3953 |
>>> |
| 3954 |
|
| 3955 |
\<configure mathml amsmath\><<< |
| 3956 |
\def\:tempc{\ifDisplayMath\mathop:prefix{}\fi\o:n:iint::} |
| 3957 |
\HLet\n:iint:\:tempc |
| 3958 |
\def\:tempc{\ifDisplayMath\mathop:prefix{}\fi\o:n:iiint::} |
| 3959 |
\HLet\n:iiint:\:tempc |
| 3960 |
\def\:tempc{\ifDisplayMath\mathop:prefix{}\fi\o:n:idotsint::} |
| 3961 |
\HLet\n:idotsint:\:tempc |
| 3962 |
>>> |
| 3963 |
|
| 3964 |
\<configure mathml fontmath\><<< |
| 3965 |
\def\:tempd#1#2{% |
| 3966 |
\expandafter\def\csname #1\endcsname{\mathchar"13#2\relax}% |
| 3967 |
\MathSymbol\mathop{#1}% |
| 3968 |
\expandafter\def\csname #1:limits\endcsname{\expandafter |
| 3969 |
\:same \math:sym\mathop{#1}\limits}% |
| 3970 |
\expandafter\ProvideDocumentCommand\csname #1:nolimits\endcsname{}{\expandafter |
| 3971 |
\:same \math:sym\mathop{#1}\nolimits}% |
| 3972 |
\expandafter\edef\csname n:#1:\endcsname{\noexpand\ifDisplayMath |
| 3973 |
\noexpand\expandafter \expandafter\noexpand \csname #1:limits\endcsname |
| 3974 |
\noexpand\else \noexpand\expandafter |
| 3975 |
\expandafter\noexpand |
| 3976 |
\csname #1:nolimits\endcsname\noexpand\fi}% |
| 3977 |
\expandafter\pend:def\csname n:#1:\endcsname{\ifDisplayMath |
| 3978 |
\mathop:prefix{}\fi}% |
| 3979 |
} |
| 3980 |
\:tempd{bigcap}{54} |
| 3981 |
\:tempd{bigcup}{53} |
| 3982 |
\:tempd{bigodot}{4A} |
| 3983 |
\:tempd{bigoplus}{4C} |
| 3984 |
\:tempd{bigotimes}{4E} |
| 3985 |
\:tempd{bigsqcup}{46} |
| 3986 |
\:tempd{biguplus}{55} |
| 3987 |
\:tempd{bigvee}{57} |
| 3988 |
\:tempd{bigwedge}{56} |
| 3989 |
\:tempd{coprod}{60} |
| 3990 |
\:tempd{intop}{52} |
| 3991 |
\:tempd{ointop}{48} |
| 3992 |
\:tempd{prod}{51} |
| 3993 |
\:tempd{sum}{50} |
| 3994 |
>>> |
| 3995 |
|
| 3996 |
Fix the \verb|\int| command -- it should produce the \verb|<mo>| element. |
| 3997 |
|
| 3998 |
\<configure mathml fontmath\><<< |
| 3999 |
\def\:tempc{\ifDisplayMath\mathop:prefix{}\fi\o:n:int::} |
| 4000 |
\HLet\n:int:\:tempc |
| 4001 |
>>> |
| 4002 |
|
| 4003 |
|
| 4004 |
\<configure mathml amsmath\><<< |
| 4005 |
\ifx \ilimits@\o:nolimits: |
| 4006 |
\let\ilimits@\nolimits |
| 4007 |
\fi |
| 4008 |
\ifx \ilimits@\o:nolimits: |
| 4009 |
\let\slimits@\nolimits |
| 4010 |
\fi |
| 4011 |
>>> |
| 4012 |
|
| 4013 |
|
| 4014 |
|
| 4015 |
\begin{description} |
| 4016 |
\item[sumlimits] |
| 4017 |
(default) Place the subscripts and superscripts of summation symbols above and below, in displayed equations. This option also affects other symbols of the same type---, , , , and so forth---but excluding integrals (see below). |
| 4018 |
|
| 4019 |
\item[nosumlimits] |
| 4020 |
Always place the subscripts and superscripts of summation-type symbols to the side, even in displayed equations. |
| 4021 |
|
| 4022 |
\item[intlimits] |
| 4023 |
Like sumlimits, but for integral symbols. |
| 4024 |
|
| 4025 |
|
| 4026 |
\<configure mathml amsmath\><<< |
| 4027 |
\ifx \ilimits@\o:displaylimits: |
| 4028 |
\let\ilimits@\nolimits |
| 4029 |
\fi |
| 4030 |
>>> |
| 4031 |
|
| 4032 |
We currently ignore cases of the following kinds. |
| 4033 |
|
| 4034 |
\begin{verbatim} |
| 4035 |
\documentclass{article} |
| 4036 |
\usepackage[intlimits]{amsmath} |
| 4037 |
\begin{document} |
| 4038 |
$\int_{0}$ |
| 4039 |
\end{document} |
| 4040 |
\end{verbatim} |
| 4041 |
|
| 4042 |
|
| 4043 |
\item[nointlimits] |
| 4044 |
(default) Opposite of intlimits. |
| 4045 |
|
| 4046 |
\item[namelimits] |
| 4047 |
(default) Like sumlimits, but for certain `operator names' such as , , , , , that traditionally have subscripts placed underneath when they occur in a displayed equation. |
| 4048 |
|
| 4049 |
\item[nonamelimits] |
| 4050 |
Opposite of namelimits. |
| 4051 |
\end{description} |
| 4052 |
|
| 4053 |
|
| 4054 |
|
| 4055 |
|
| 4056 |
\<\><<< |
| 4057 |
\pend:def\n:int:{\ifDisplayMath\mathop:prefix{mathsize="big"}\fi} |
| 4058 |
\def\sum{\mathchar"1350} |
| 4059 |
\MathSymbol\mathop{sum} |
| 4060 |
\def\sum:limits{\expandafter\:same \math:sym\mathop{sum}\limits} |
| 4061 |
\def\sum:nolimits{\expandafter\:same \math:sym\mathop{sum}\nolimits} |
| 4062 |
\def\n:sum:{\ifDisplayMath \expandafter\sum:limits\else |
| 4063 |
\expandafter\sum:nolimits\fi} |
| 4064 |
\pend:def\n:sum:{\ifDisplayMath\mathop:prefix{mathsize="big"}\fi} |
| 4065 |
>>> |
| 4066 |
|
| 4067 |
% % \def\n:sum:{\expandafter\:same \math:sym\mathop{sum}\nolimits} |
| 4068 |
|
| 4069 |
|
| 4070 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4071 |
\section{Accent through `accents' Configurations} |
| 4072 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4073 |
|
| 4074 |
Should rename `accents' to `combining' (characters). |
| 4075 |
|
| 4076 |
|
| 4077 |
Test file for accents |
| 4078 |
|
| 4079 |
\begin{verbatim} |
| 4080 |
\documentclass{article} |
| 4081 |
\begin{document} |
| 4082 |
|
| 4083 |
\def\showaccents#1#2#3#4#5#6{\cr\hline |
| 4084 |
{\tt \ifx #1\relax\else \string#1\fi{} \string#2} & |
| 4085 |
\if !#3!\else $\ifx #1\relax\else#1{#3}\fi |
| 4086 |
\mbox{#2{#3}}$ {\bf #2{#3}}\fi & |
| 4087 |
\if !#4!\else $\ifx #1\relax\else#1{#4}\fi |
| 4088 |
\mbox{#2{#4}}$ {\bf #2{#4}}\fi & |
| 4089 |
\if !#5!\else $\ifx #1\relax\else#1{#5}\fi |
| 4090 |
\mbox{#2{#5}}$ {\bf #2{#5}}\fi |
| 4091 |
\if !#6!\else |
| 4092 |
\if !#6!\else $\ifx #1\relax\else#1{#6}\fi |
| 4093 |
\mbox{#2{#6}}$ {\bf #2{#6}}\fi |
| 4094 |
\fi |
| 4095 |
} |
| 4096 |
|
| 4097 |
\begin{tabular}{l|c|c|c} |
| 4098 |
& low unicode & high unicode & text combining accent \& mathml |
| 4099 |
\showaccents\dot\.{c}{a}{q}{X} |
| 4100 |
\showaccents\breve\u{a}{}{c}{F} |
| 4101 |
\showaccents\check\v{a}{h}{m}{F} |
| 4102 |
\showaccents\bar\={a}{y}{c}{F} |
| 4103 |
\showaccents\grave\`{a}{n}{c}{F} |
| 4104 |
\showaccents\acute\'{a}{}{m}{F} |
| 4105 |
\showaccents\hat\^{a}{z}{m}{F} |
| 4106 |
\showaccents\tilde\~{a}{v}{m}{F} |
| 4107 |
\showaccents\ddot\"{a}{h}{m}{C} |
| 4108 |
\showaccents\mathring\r{a}{}{m}{F} |
| 4109 |
\showaccents\relax\b{}{b}{c}{j} |
| 4110 |
\showaccents\relax\c{c}{d}{a}{j} |
| 4111 |
\showaccents\relax\d{a}{b}{c}{j} |
| 4112 |
\showaccents\relax\H{o}{}{c}{F} |
| 4113 |
\end{tabular} |
| 4114 |
|
| 4115 |
\end{document} |
| 4116 |
\end{verbatim} |
| 4117 |
|
| 4118 |
|
| 4119 |
|<temp indirect accents|> |
| 4120 |
|
| 4121 |
\<config mathml accents\><<< |
| 4122 |
\Configure{accents} |
| 4123 |
{\ifmmode \expandafter\mathord\fi |
| 4124 |
{|<temp hcode accents|>% |
| 4125 |
\ht:special{t4ht@[}\if!#1!x\else#2\fi |
| 4126 |
\ht:special{t4ht@]}}} |
| 4127 |
{\ifmathml |
| 4128 |
\ifmtext |<accent in text mode|>% |
| 4129 |
\else \AccentMath{|<under over accents|>}\fi |
| 4130 |
\else |<accent in text mode|>\fi |
| 4131 |
} |
| 4132 |
>>> |
| 4133 |
|
| 4134 |
\<accent in text mode\><<< |
| 4135 |
\expandafter\ifx \csname :#1:over\endcsname\relax |
| 4136 |
\expandafter\ifx \csname :#1:under\endcsname\relax |
| 4137 |
\AccentMath{|<under over accents|>}% |
| 4138 |
\else #3\csname :#1:under\endcsname \fi |
| 4139 |
\else #3\csname :#1:over\endcsname \fi |
| 4140 |
>>> |
| 4141 |
|
| 4142 |
\<under over accents\><<< |
| 4143 |
\expandafter\ifx \csname :#1:over\endcsname\relax |
| 4144 |
|<under accents|>% |
| 4145 |
\else \expandafter\ifx \csname :#1:under\endcsname\relax |
| 4146 |
|<over accents|>% |
| 4147 |
\else |
| 4148 |
|<both accents|>% |
| 4149 |
\fi \fi |
| 4150 |
>>> |
| 4151 |
|
| 4152 |
\<under accents\><<< |
| 4153 |
\HCode{<\a:mathml munder\Hnewline |
| 4154 |
accent="true"><\a:mathml mrow\Hnewline>}#3\HCode{</\a:mathml mrow>}% |
| 4155 |
\csname :#1:under\endcsname |
| 4156 |
\HCode{</\a:mathml munder>}% |
| 4157 |
>>> |
| 4158 |
|
| 4159 |
\<over accents\><<< |
| 4160 |
\HCode{<\a:mathml mover\Hnewline |
| 4161 |
accent="true"><\a:mathml mrow\Hnewline>}#3\HCode{</\a:mathml mrow>}% |
| 4162 |
\csname :#1:over\endcsname |
| 4163 |
\HCode{</\a:mathml mover>}% |
| 4164 |
>>> |
| 4165 |
|
| 4166 |
\<both accents\><<< |
| 4167 |
\HCode{<\a:mathml munderover\Hnewline |
| 4168 |
accent="true"><\a:mathml mrow\Hnewline>}#3\HCode{</\a:mathml mrow>}% |
| 4169 |
\csname :#1:under\endcsname |
| 4170 |
\csname :#1:over\endcsname |
| 4171 |
\HCode{</\a:mathml munderover>}% |
| 4172 |
>>> |
| 4173 |
|
| 4174 |
|
| 4175 |
|
| 4176 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4177 |
\section{Underline and Overline} |
| 4178 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4179 |
|
| 4180 |
|
| 4181 |
\<configure html-mml latex\><<< |
| 4182 |
\Configure{overline} |
| 4183 |
{\bgroup\ifmathml |<mathml overline|>\else |
| 4184 |
\HCode{<span class="overline">}\fi} |
| 4185 |
{\ifmathml |<end mathml overline|>\else \HCode{</span>}\fi\egroup} |
| 4186 |
\Configure{underline} |
| 4187 |
{\bgroup |
| 4188 |
\ifmathml |<mathml underline|>% |
| 4189 |
\else |<nomath underline|>\HCode{<span class="underline">}\fi} |
| 4190 |
{\ifmathml |<end mathml underline|>\else \HCode{</span>}\fi \egroup} |
| 4191 |
>>> |
| 4192 |
|
| 4193 |
|
| 4194 |
\<configure mathml ushort\><<< |
| 4195 |
\Configure{ushort} |
| 4196 |
{\bgroup |
| 4197 |
\expandafter\ushort:data |
| 4198 |
} |
| 4199 |
{\egroup} |
| 4200 |
\Configure{ushortw} |
| 4201 |
{\bgroup |
| 4202 |
\expandafter\ushort:data |
| 4203 |
} |
| 4204 |
{\egroup} |
| 4205 |
\Configure{ushortd} |
| 4206 |
{\bgroup |
| 4207 |
\expandafter\ushortd:data |
| 4208 |
} |
| 4209 |
{\egroup} |
| 4210 |
\Configure{ushortdw} |
| 4211 |
{\bgroup |
| 4212 |
\expandafter\ushortd:data |
| 4213 |
} |
| 4214 |
{\egroup} |
| 4215 |
\Configure{ushortdline} |
| 4216 |
{\bgroup\expandafter\ushortdline:data } |
| 4217 |
{\egroup} |
| 4218 |
\def\ushort:data#1#2{\underline{\:gobbleIII #2}} |
| 4219 |
\def\ushortd:data#1#2{\underline{\underline{\:gobbleIII #2}}} |
| 4220 |
\def\ushortdline:data#1#2{#1{#1{\:gobble #2}}} |
| 4221 |
>>> |
| 4222 |
|
| 4223 |
|
| 4224 |
\<mathml latex\><<< |
| 4225 |
|<und/ov-erline|> |
| 4226 |
>>> |
| 4227 |
|
| 4228 |
\<mathml plain\><<< |
| 4229 |
|<und/ov-erline|> |
| 4230 |
>>> |
| 4231 |
|
| 4232 |
|
| 4233 |
\<und/ov-erline\><<< |
| 4234 |
\Configure{overline} |
| 4235 |
{\bgroup |<mathml overline|>} |
| 4236 |
{|<end mathml overline|>\egroup} |
| 4237 |
\Configure{underline} |
| 4238 |
{\bgroup \ifmmode |<mathml underline|>\else |
| 4239 |
|<nomath underline|>\fi} |
| 4240 |
{|<end mathml underline|>\egroup} |
| 4241 |
>>> |
| 4242 |
|
| 4243 |
\<nomath underline\><<< |
| 4244 |
\expandafter\everymath |
| 4245 |
\expandafter{\expandafter\everymath |
| 4246 |
\expandafter{\the\everymath}}% |
| 4247 |
\let\o::@underline:\o:@@underline: |
| 4248 |
\def\o:@@underline:{\let\o:@@underline:\o::@underline:}% |
| 4249 |
>>> |
| 4250 |
|
| 4251 |
|
| 4252 |
|
| 4253 |
|
| 4254 |
|
| 4255 |
|
| 4256 |
|
| 4257 |
|
| 4258 |
|
| 4259 |
|
| 4260 |
|
| 4261 |
\<mathml overline\><<< |
| 4262 |
\HCode{<\a:mathml mover accent="false"\Hnewline |
| 4263 |
\mml:class="mml-overline"><\a:mathml mrow>}% |
| 4264 |
>>> |
| 4265 |
|
| 4266 |
\<end mathml overline\><<< |
| 4267 |
\HCode{</\a:mathml mrow><\a:mathml mo\Hnewline |
| 4268 |
accent="true">&\#x00AF;</\a:mathml mo>% |
| 4269 |
</\a:mathml mover>}% |
| 4270 |
>>> |
| 4271 |
|
| 4272 |
\verb'¯' is the code of \verb'‾' |
| 4273 |
|
| 4274 |
|
| 4275 |
\<mathml underline\><<< |
| 4276 |
\HCode{<\a:mathml munder \a:mathml accentunder="false"\Hnewline |
| 4277 |
\mml:class="mml-underline"><\a:mathml mrow>}% |
| 4278 |
>>> |
| 4279 |
|
| 4280 |
\<end mathml underline\><<< |
| 4281 |
\HCode{</\a:mathml mrow><\a:mathml mo\Hnewline |
| 4282 |
accent="true">&\#x0332;</\a:mathml mo></\a:mathml munder>}% |
| 4283 |
>>> |
| 4284 |
|
| 4285 |
|
| 4286 |
\verb'̲' is the code of \verb'_' |
| 4287 |
|
| 4288 |
|
| 4289 |
|
| 4290 |
|
| 4291 |
|
| 4292 |
\<mathml plain\><<< |
| 4293 |
|<arr: amsmath, amstex1|> |
| 4294 |
>>> |
| 4295 |
|
| 4296 |
|
| 4297 |
|
| 4298 |
\<configure mathml accents\><<< |
| 4299 |
\Configure{accentset} |
| 4300 |
{\HCode{<mover accent="true" class="accentset"><mrow>}} |
| 4301 |
{\HCode{</mrow><mrow> }} |
| 4302 |
{\HCode{</mrow></mover>}} |
| 4303 |
\Configure{underaccent} |
| 4304 |
{\HCode{<munder class="underaccent"><mrow>}} |
| 4305 |
{\HCode{</mrow><mrow> }} |
| 4306 |
{\HCode{</mrow></munder>}} |
| 4307 |
>>> |
| 4308 |
|
| 4309 |
Support for the Ulem package in MathML. It seems that text-decoration CSS |
| 4310 |
property doesn't work in browsers for Mathml, so we need to use various tricks |
| 4311 |
to emulate effects, especially double, dotted and dashed lines. |
| 4312 |
|
| 4313 |
\<configure mathml ulem\><<< |
| 4314 |
\Configure{uline-math} |
| 4315 |
{\HCode{<\a:mathml menclose class="uline-math" notation="bottom">}\NoFonts} {\EndNoFonts\HCode{</\a:mathml menclose>}} |
| 4316 |
\Configure{uuline-math} |
| 4317 |
{\HCode{<\a:mathml menclose class="uuline-math" notation="bottom">}\NoFonts} {\EndNoFonts\HCode{</\a:mathml menclose>}} |
| 4318 |
\Css{.uuline-math{ border-bottom:3px double black; }} |
| 4319 |
\Configure{sout-math} |
| 4320 |
{\HCode{<\a:mathml menclose class="sout-math" notation="horizontalstrike">}\NoFonts} {\EndNoFonts\HCode{</\a:mathml menclose>}} |
| 4321 |
\Configure{xout-math} |
| 4322 |
{\HCode{<\a:mathml menclose class="xout-math" notation="horizontalstrike bottom">}\NoFonts} |
| 4323 |
{\EndNoFonts\HCode{</\a:mathml menclose>}} |
| 4324 |
\Configure{uwave-math} |
| 4325 |
{\HCode{<\a:mathml menclose class="uwave-math" notation="bottom">}\NoFonts} |
| 4326 |
{\EndNoFonts\HCode{</\a:mathml menclose>}} |
| 4327 |
\Configure{dashuline-math} |
| 4328 |
{\HCode{<\a:mathml mstyle class="dashuline-math" notation="bottom">}\NoFonts} |
| 4329 |
{\EndNoFonts\HCode{</\a:mathml mstyle>}} |
| 4330 |
\Css{.dashuline-math {border-bottom: 1px dashed black;}} |
| 4331 |
\Configure{dotuline-math} |
| 4332 |
{\HCode{<\a:mathml mstyle class="dotuline-math" notation="bottom">}\NoFonts} |
| 4333 |
{\EndNoFonts\HCode{</\a:mathml mstyle>}} |
| 4334 |
\Css{.dotuline-math {border-bottom: 1px dotted black;}} |
| 4335 |
>>> |
| 4336 |
|
| 4337 |
Support for the Cancel package |
| 4338 |
|
| 4339 |
\<configure mathml cancel\><<< |
| 4340 |
\Configure{cancel-math}{\HCode{<\a:mathml menclose notation="updiagonalstrike">}}{\HCode{</\a:mathml menclose>}} |
| 4341 |
\Configure{bcancel-math}{\HCode{<\a:mathml menclose notation="downdiagonalstrike">}}{\HCode{</\a:mathml menclose>}} |
| 4342 |
\Configure{xcancel-math}{\HCode{<\a:mathml menclose notation="updiagonalstrike downdiagonalstrike">}}{\HCode{</\a:mathml menclose>}} |
| 4343 |
\Configure{cancelto} |
| 4344 |
{\HCode{<\a:mathml msup><\a:mathml menclose notation="updiagonalarrow"><\a:mathml mrow>}} |
| 4345 |
{\HCode{</\a:mathml mrow></\a:mathml menclose><\a:mathml mrow>}} |
| 4346 |
{\HCode{</\a:mathml mrow></\a:mathml msup>}} |
| 4347 |
>>> |
| 4348 |
|
| 4349 |
|
| 4350 |
|
| 4351 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4352 |
\section{Choose} |
| 4353 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4354 |
|
| 4355 |
\<plain,latex mathmlNO\><<< |
| 4356 |
\Configure{choose} |
| 4357 |
{\Send{GROUP}{0}{<\a:mathml mfrac linethickness="0" \mml:class="choose">\Hnewline |
| 4358 |
<\a:mathml mrow \mml:class="choose-1">}\HCode{</\a:mathml mrow>}} |
| 4359 |
{\HCode{\Hnewline<\a:mathml mrow \mml:class="choose-2">} |
| 4360 |
\Send{EndGROUP}{0}{</\a:mathml mrow></\a:mathml mfrac>}} |
| 4361 |
>>> |
| 4362 |
|
| 4363 |
|
| 4364 |
|
| 4365 |
|
| 4366 |
|
| 4367 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4368 |
\section{Footnotes} |
| 4369 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4370 |
|
| 4371 |
\<configure html-mml latex\><<< |
| 4372 |
\Configure{footnote-mark} |
| 4373 |
{\ifmathml \ifmtext \else |
| 4374 |
\HCode{<\a:mathml mrow \mml:class="footnote-mark">}\fi |
| 4375 |
\else \HCode{<span class="footnote-mark">}\fi } |
| 4376 |
{\ifmathml \ifmtext \else \HCode{</\a:mathml mrow>}\fi |
| 4377 |
\else \HCode{</span>}\fi } |
| 4378 |
\Configure{thank-mark} |
| 4379 |
{\HCode{<\ifmathml \a:mathml mrow \expandafter\mml:class\else span class\fi |
| 4380 |
="thank-mark">}} |
| 4381 |
{\HCode{</\ifmathml \a:mathml mrow\else span\fi>}} |
| 4382 |
>>> |
| 4383 |
|
| 4384 |
|
| 4385 |
|
| 4386 |
|
| 4387 |
|
| 4388 |
The following code segments handle the different listed cases, |
| 4389 |
with possible exception of the last. |
| 4390 |
|
| 4391 |
\begin{verbatim} |
| 4392 |
a\footnote{b c} |
| 4393 |
|
| 4394 |
$a\footnote{b c}$ |
| 4395 |
|
| 4396 |
$a\footnote{\hbox{b c}}$ |
| 4397 |
|
| 4398 |
$a\footnote{\mbox{b c}}$ |
| 4399 |
|
| 4400 |
$a\mbox{\footnote{b c}}$ |
| 4401 |
\end{verbatim} |
| 4402 |
|
| 4403 |
|
| 4404 |
We have the following hooks |
| 4405 |
|
| 4406 |
|
| 4407 |
\begin{verbatim} |
| 4408 |
\def\@footnotemark{...\a:@makefnmark\@makefnmark |
| 4409 |
\b:@makefnmark...} |
| 4410 |
\long\def\@footnotetext#1{...\a:footnote-text\a:@makefntext |
| 4411 |
\@makefntext{\b:@makefntext |
| 4412 |
\a:@makefnbody #1\b:@makefnbody |
| 4413 |
}\c:@makefntext\b:footnote-text...} |
| 4414 |
\end{verbatim} |
| 4415 |
|
| 4416 |
|
| 4417 |
|
| 4418 |
|
| 4419 |
|
| 4420 |
\<configure html-mml latex\><<< |
| 4421 |
\:CheckOption{fn-in}\if:Option \else |
| 4422 |
\expandafter\let\csname A:footnote-text\expandafter\endcsname |
| 4423 |
\csname a:footnote-text\endcsname |
| 4424 |
\expandafter\let\csname B:footnote-text\expandafter\endcsname |
| 4425 |
\csname b:footnote-text\endcsname |
| 4426 |
\NewConfigure{footnote-text}[2]{% |
| 4427 |
\expandafter\def\csname a:footnote-text\endcsname{% |
| 4428 |
#1% |
| 4429 |
\ifmathml |
| 4430 |
\HCode{<\a:mathml math\Hnewline |
| 4431 |
\csname a:math-xmlns\endcsname \Hnewline \a:@math>% |
| 4432 |
\ifmtext <\a:mathml mtext>\fi} |
| 4433 |
\fi |
| 4434 |
\ifmathml \fi |
| 4435 |
}% |
| 4436 |
\expandafter\def\csname b:footnote-text\endcsname{% |
| 4437 |
\ifmathml |
| 4438 |
\HCode{\ifmtext</\a:mathml mtext>\fi </\a:mathml math>}% |
| 4439 |
\fi |
| 4440 |
#2% |
| 4441 |
}% |
| 4442 |
} |
| 4443 |
\Configure{footnote-text} |
| 4444 |
{\csname A:footnote-text\endcsname} |
| 4445 |
{\csname B:footnote-text\endcsname} |
| 4446 |
\fi |
| 4447 |
>>> |
| 4448 |
|
| 4449 |
|
| 4450 |
|
| 4451 |
\<configure html-mml latex\><<< |
| 4452 |
\let\A:footnotetext=\a:footnotetext |
| 4453 |
\let\B:footnotetext=\b:footnotetext |
| 4454 |
\let\C:footnotetext=\c:footnotetext |
| 4455 |
\NewConfigure{footnotetext}[3]{% |
| 4456 |
\def\a:footnotetext{% |
| 4457 |
\ifmathml \ifmtext |<end mtext space|>\fi\fi |
| 4458 |
#1% |
| 4459 |
\ifmathml \ifmtext |<end mtext space|>\fi\fi |
| 4460 |
}% |
| 4461 |
\def\b:footnotetext{% |
| 4462 |
\ifmathml \ifmtext |<end mtext space|>\fi\fi |
| 4463 |
#2% |
| 4464 |
\ifmathml \ifmtext |<end mtext space|>\fi\fi |
| 4465 |
}% |
| 4466 |
\def\c:footnotetext{% |
| 4467 |
\ifmathml \ifmtext |<end mtext space|>\fi\fi |
| 4468 |
#3% |
| 4469 |
\ifmathml \ifmtext |<start mtext space|>\fi\fi |
| 4470 |
}% |
| 4471 |
} |
| 4472 |
\Configure{footnotetext} |
| 4473 |
{\A:footnotetext} |
| 4474 |
{\B:footnotetext} |
| 4475 |
{\C:footnotetext} |
| 4476 |
>>> |
| 4477 |
|
| 4478 |
\<configure html-mml latex\><<< |
| 4479 |
\Configure{footnotebody} |
| 4480 |
{\tmp:toks=} |
| 4481 |
{\ifmathml \ifmmode $\mbox{$\the\tmp:toks$}$ |
| 4482 |
\else $\mbox{\the\tmp:toks}$\fi |
| 4483 |
\else \the\tmp:toks\fi} |
| 4484 |
>>> |
| 4485 |
|
| 4486 |
|
| 4487 |
\<configure html-mml latex\><<< |
| 4488 |
\:CheckOption{mouseover} \if:Option |
| 4489 |
\pend:def\js:on{\ifmathml \ifmtext |<end mtext space|>\fi\fi} |
| 4490 |
\append:def\js:on{\ifmathml \ifmtext |<start mtext space|>\fi\fi} |
| 4491 |
\fi |
| 4492 |
>>> |
| 4493 |
|
| 4494 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4495 |
\section{Space Characters} |
| 4496 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4497 |
|
| 4498 |
We must use \`'\protect' with LaTeX in order to support TOC etc. |
| 4499 |
|
| 4500 |
\<plain,latex mathml\><<< |
| 4501 |
\ifdefined\protect% |
| 4502 |
\def\:unicodespace{\protect\leavevmode\special{t4ht@+\string&{35}x00A0{59}}x}% |
| 4503 |
\def\:unicodenspace{\protect\leavevmode\special{t4ht@+\string&{35}x2002{59}}x}% |
| 4504 |
\else% |
| 4505 |
\def\:unicodespace{\leavevmode\special{t4ht@+\string&{35}x00A0{59}}x}% |
| 4506 |
\def\:unicodenspace{\leavevmode\special{t4ht@+\string&{35}x2002{59}}x}% |
| 4507 |
\fi |
| 4508 |
\def\:nbsp{\ifmtext |<unicode space|>\else\ifmathml |
| 4509 |
\Tg<\a:mathml mspace />\else |<unicode space|>\fi\fi} |
| 4510 |
\def\:ensp{\ifmtext |<unicode enspace|>\else\ifmathml |
| 4511 |
\Tg<\a:mathml mspace />\else |<unicode enspace|>\fi\fi} |
| 4512 |
>>> |
| 4513 |
|
| 4514 |
\<unicode space\><<< |
| 4515 |
\:unicodespace% |
| 4516 |
>>> |
| 4517 |
|
| 4518 |
\<unicode enspace\><<< |
| 4519 |
\:unicodenspace% |
| 4520 |
>>> |
| 4521 |
% \HCode{\string&}\HChar{-35}\HCode{x00A0;}% |
| 4522 |
|
| 4523 |
|
| 4524 |
\<configure html-mml frenchb\><<< |
| 4525 |
\Configure{frenchb-nbsp} |
| 4526 |
{\ifmtext |<unicode space|>\else\ifmathml |
| 4527 |
\Tg<\a:mathml mspace class="frenchb-nbsp" />% |
| 4528 |
\else |
| 4529 |
\ht:special{t4ht@?unhskip}\HCode{<span class="frenchb-thinspace">}% |
| 4530 |
|<unicode space|>\HCode{</span>}% |
| 4531 |
\fi\fi |
| 4532 |
\setbox\tmp:bx=\hbox\bgroup} |
| 4533 |
{\egroup} |
| 4534 |
>>> |
| 4535 |
|
| 4536 |
|
| 4537 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4538 |
\section{Matrices} |
| 4539 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 4540 |
|
| 4541 |
%%%%%%%%%%%%% |
| 4542 |
\subsection{Aligned} |
| 4543 |
%%%%%%%%%%%%% |
| 4544 |
|
| 4545 |
|
| 4546 |
|
| 4547 |
\<configure mathml amsmath\><<< |
| 4548 |
% thanks to Linas Stonys for this code |
| 4549 |
\def\mtable:align:attribute{% |
| 4550 |
\if t\Hlcr\space\a:mathml align="axis 1"\fi |
| 4551 |
\if b\Hlcr\space\a:mathml align="axis -1"\fi |
| 4552 |
} |
| 4553 |
|
| 4554 |
\Configure{aligned} |
| 4555 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="aligned" \a:mathml displaystyle="true" \mtable:align:attribute>}} |
| 4556 |
{\HCode{</\a:mathml mtable>}} |
| 4557 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4558 |
{\HCode{<\a:mathml mtd |
| 4559 |
\a:mathml columnalign="\ifodd\HCol right\else left\fi" >}} |
| 4560 |
{\HCode{</\a:mathml mtd>}} |
| 4561 |
\Configure{alignedat} |
| 4562 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="alignedat" \a:mathml displaystyle="true" \mtable:align:attribute>}} |
| 4563 |
{\HCode{</\a:mathml mtable>}} |
| 4564 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4565 |
{\HCode{<\a:mathml mtd |
| 4566 |
\a:mathml columnalign="\ifodd\HCol right\else left\fi" >}} |
| 4567 |
{\HCode{</\a:mathml mtd>}} |
| 4568 |
>>> |
| 4569 |
|
| 4570 |
|
| 4571 |
|
| 4572 |
%%%%%%%%%%%%%%%%%%%% |
| 4573 |
\subsection{Cases} |
| 4574 |
%%%%%%%%%%%%%%%%% |
| 4575 |
|
| 4576 |
\<plain,latex mathml\><<< |
| 4577 |
\Configure{cases} |
| 4578 |
{}{} {\Tg<\a:mathml mtable>}{\Tg</\a:mathml mtable>} |
| 4579 |
{\Tg<\a:mathml mtr>}{\Tg</\a:mathml mtr>} |
| 4580 |
{\Tg<\a:mathml mtd \mml:class="cases">}{\Tg</\a:mathml mtd>} |
| 4581 |
>>> |
| 4582 |
|
| 4583 |
|
| 4584 |
%%%%%%%%%%%%%%%%%%%% |
| 4585 |
\subsection{matrix} |
| 4586 |
%%%%%%%%%%%%%%%%%%%% |
| 4587 |
|
| 4588 |
\<plain,latex mathml\><<< |
| 4589 |
\Configure{matrix} |
| 4590 |
{\Tg<\a:mathml mtable |
| 4591 |
\a:mathml equalrows="false" \a:mathml equalcolumns="false"\Hnewline |
| 4592 |
\mml:class="matrix">} |
| 4593 |
{\Tg</\a:mathml mtable>} |
| 4594 |
{\Tg<\a:mathml mtr>}{\Tg</\a:mathml mtr>} |
| 4595 |
{|<mtd matrix|>}{\Tg</\a:mathml mtd>} |
| 4596 |
>>> |
| 4597 |
|
| 4598 |
|
| 4599 |
|
| 4600 |
%%%%%%%%%%%%%%%%%%%% |
| 4601 |
\subsection{pmatrix} |
| 4602 |
%%%%%%%%%%%%%%%%%%%% |
| 4603 |
|
| 4604 |
|
| 4605 |
The grouping below is handle the case that the matrix is a base of an exponent. |
| 4606 |
|
| 4607 |
|
| 4608 |
\<plain,latex mathml\><<< |
| 4609 |
\Configure{pmatrix} {\bgroup\Tg<\a:mathml mrow\Hnewline |
| 4610 |
\mml:class="pmatrix">} {\Tg</\a:mathml mrow>\egroup} |
| 4611 |
>>> |
| 4612 |
|
| 4613 |
|
| 4614 |
|
| 4615 |
The grouping below is handle the case that the matrix is a base of an |
| 4616 |
exponent. The \verb|\,| configurations is for facilitating the |
| 4617 |
catching of left subscripts and superscripts. |
| 4618 |
|
| 4619 |
|
| 4620 |
\<plain,latex mathml\><<< |
| 4621 |
\Configure{quad}{{\ifmathml \ifmtext \o:quad:\else |
| 4622 |
{\HCode{<\a:mathml mspace width="1em" \mml:class="quad"/>}}\fi |
| 4623 |
\else \o:quad: \fi}} |
| 4624 |
\Configure{qquad}{{\ifmathml \ifmtext \o:qquad:\else |
| 4625 |
{\HCode{<\a:mathml mspace width="2em" \mml:class="qquad"/>}}\fi |
| 4626 |
\else \o:qquad: \fi}} |
| 4627 |
\Configure{,} |
| 4628 |
{{\HCode{<\a:mathml mspace width="0.17em" \mml:class="thinspace"/>}}} |
| 4629 |
\Configure{:} |
| 4630 |
{{\HCode{<\a:mathml mspace width="0.22em" \mml:class="thinspace"/>}}} |
| 4631 |
\Configure{;} |
| 4632 |
{{\HCode{<\a:mathml mspace width="0.28em" \mml:class="thickpace"/>}}} |
| 4633 |
\Configure{>} |
| 4634 |
{{\HCode{<\a:mathml mspace width="0.30em" \mml:class="medspace"/>}}} |
| 4635 |
\Configure{!} |
| 4636 |
{{\HCode{<\a:mathml mspace width="-0.17em" \mml:class="negthinspace"/>}}} |
| 4637 |
>>> |
| 4638 |
|
| 4639 |
|
| 4640 |
%%%%%%%%%%%%% |
| 4641 |
\subsection{Array Border Lines} |
| 4642 |
%%%%%%%%%%%%% |
| 4643 |
|
| 4644 |
|
| 4645 |
\<border lines\><<< |
| 4646 |
\border:lines |
| 4647 |
>>> |
| 4648 |
|
| 4649 |
\<configure html-mml latex\><<< |
| 4650 |
\def\border:lines{% |
| 4651 |
\ifnum \borderlines>0 |
| 4652 |
\ifnum \borderlines>1 border-right:solid 1px black;\fi |
| 4653 |
\ifodd \borderlines border-left:solid 1px black;\fi |
| 4654 |
\fi |
| 4655 |
} |
| 4656 |
>>> |
| 4657 |
|
| 4658 |
|
| 4659 |
|
| 4660 |
|
| 4661 |
\<config array\><<< |
| 4662 |
\Configure{VBorder} |
| 4663 |
{\HAssign\NewGroup = 0 |
| 4664 |
|<init vborder|>} |
| 4665 |
{|<vborder solid|>% |
| 4666 |
\HAssign\NewGroup = 0} |
| 4667 |
{\Advance:\NewGroup by 1 |
| 4668 |
|<record cur vborder|>} |
| 4669 |
{} |
| 4670 |
>>> |
| 4671 |
|
| 4672 |
|
| 4673 |
|
| 4674 |
\<vborder html-mml latex/array\><<< |
| 4675 |
\Configure{VBorder} |
| 4676 |
{\let\VBorder=\empty \let\AllColMargins=\empty |
| 4677 |
\global\let\GROUPS=\empty \HAssign\NewGroup = 0 |
| 4678 |
\gHAdvance\Next:TableNo by 1 \global\let\TableNo=\Next:TableNo |
| 4679 |
|<init vborder|>% |
| 4680 |
} |
| 4681 |
{|<vborder solid|>% |
| 4682 |
\xdef\VBorder{\VBorder\ifnum \NewGroup> 0 </colgroup>\fi} |
| 4683 |
\HAssign\NewGroup = 0 \gdef\GROUPS{rules="groups"}} |
| 4684 |
{\Advance:\NewGroup by 1 |
| 4685 |
|<record cur vborder|>% |
| 4686 |
\ifnum \NewGroup=1 \xdef\VBorder{\VBorder<colgroup |
| 4687 |
id="TBL-\TableNo-\ar:cnt g">}\fi |
| 4688 |
\xdef\VBorder{\VBorder<col\Hnewline id="TBL-\TableNo |
| 4689 |
-\ar:cnt"\xml:empty>}\xdef\AllColMargins{\AllColMargins1}} |
| 4690 |
{\xdef\AllColMargins{\AllColMargins 0}} |
| 4691 |
\Configure{putHBorder}{\bgroup\ifmathml\mathml:hborder\fi\HCode{\HBorder}\egroup} |
| 4692 |
>>> |
| 4693 |
|
| 4694 |
|
| 4695 |
|
| 4696 |
\<init vborder\><<< |
| 4697 |
\HAssign\borderlines = 0 |
| 4698 |
\global\let\columnlines=\relax |
| 4699 |
>>> |
| 4700 |
|
| 4701 |
\<vborder solid\><<< |
| 4702 |
\ifx \columnlines\relax \gHAssign\borderlines = 1 |
| 4703 |
\else \gHAdvance\borderlines by 2 \fi |
| 4704 |
>>> |
| 4705 |
|
| 4706 |
|
| 4707 |
\<record cur vborder\><<< |
| 4708 |
\ifnum \borderlines>1 \gHAdvance\borderlines by -2 \fi |
| 4709 |
\ifx \columnlines\relax |
| 4710 |
\global\let\columnlines\empty |
| 4711 |
\else |
| 4712 |
\ifnum \NewGroup=1 |
| 4713 |
\xdef\columnlines{\columnlines\ifx\columnlines\empty |
| 4714 |
\else \space\fi solid}% |
| 4715 |
\else |
| 4716 |
\xdef\columnlines{\columnlines\ifx\columnlines\empty |
| 4717 |
\else \space\fi none}% |
| 4718 |
\fi |
| 4719 |
\fi |
| 4720 |
>>> |
| 4721 |
|
| 4722 |
\<configure html-mml array\><<< |
| 4723 |
|<vborder html-mml latex/array|> |
| 4724 |
>>> |
| 4725 |
|
| 4726 |
\<configure html-mml latex\><<< |
| 4727 |
|<vborder html-mml latex/array|> |
| 4728 |
>>> |
| 4729 |
|
| 4730 |
|
| 4731 |
|
| 4732 |
|
| 4733 |
|
| 4734 |
%%%%%%%%%%%%%%%%%%%% |
| 4735 |
\section{TeX} |
| 4736 |
%%%%%%%%%%%%%%%%%%%% |
| 4737 |
|
| 4738 |
|
| 4739 |
\<mathml plain\><<< |
| 4740 |
\Configure{eqalignno} |
| 4741 |
{\HCode{<\a:mathml mtable \mml:class="eqalignno">}} |
| 4742 |
{\HCode{</\a:mathml mtable>}} |
| 4743 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="eqalignno">}} |
| 4744 |
{\HCode{</\a:mathml mtr>}} |
| 4745 |
{\HCode{<\a:mathml mtd \Hnewline \mml:class="eqalignno-\HCol">}} |
| 4746 |
{\HCode{</\a:mathml mtd>}} |
| 4747 |
\def\:eqalignno:{\Configure{noalign} |
| 4748 |
{\HCode{<\a:mathml mtr><\a:mathml mtd \mml:class="noalign" colspan="2">}}% |
| 4749 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}}} |
| 4750 |
>>> |
| 4751 |
|
| 4752 |
|
| 4753 |
\<mathml plain\><<< |
| 4754 |
\Configure{leqalignno} |
| 4755 |
{\HCode{<\a:mathml mtable \mml:class="leqalignno">}} |
| 4756 |
{\HCode{</\a:mathml mtable>}} |
| 4757 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="leqalignno">}} |
| 4758 |
{\HCode{</\a:mathml mtr>}} |
| 4759 |
{\HCode{<\a:mathml mtd \Hnewline \mml:class="leqalignno-\HCol">}} |
| 4760 |
{\HCode{</\a:mathml mtd>}} |
| 4761 |
\def\:leqalignno:{\Configure{noalign} |
| 4762 |
{\HCode{<\a:mathml mtr><\a:mathml mtd \mml:class="noalign" colspan="2">}}% |
| 4763 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}}} |
| 4764 |
>>> |
| 4765 |
|
| 4766 |
\section{Fractions} |
| 4767 |
|
| 4768 |
|
| 4769 |
|
| 4770 |
|
| 4771 |
|
| 4772 |
|
| 4773 |
|
| 4774 |
\<amstex.sty mathml\><<< |
| 4775 |
|<config mathml amstex1|> |
| 4776 |
>>> |
| 4777 |
|
| 4778 |
|
| 4779 |
\<config mathml amstex1\><<< |
| 4780 |
\ConfigureEnv{aligned}{}{}{}{} |
| 4781 |
\Configure{aligned} |
| 4782 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="aligned">}} |
| 4783 |
{\HCode{</\a:mathml mtable>}} |
| 4784 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4785 |
{\HCode{<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 4786 |
>>> |
| 4787 |
|
| 4788 |
|
| 4789 |
\<amstex.tex mathml\><<< |
| 4790 |
\Configure{multilimits} |
| 4791 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="multilimits">}} |
| 4792 |
{\HCode{</\a:mathml mtable>}} |
| 4793 |
{\HCode{<\a:mathml mtr><\a:mathml mtd\Hnewline>}} |
| 4794 |
{\HCode{</\a:mathml mtd></\a:mathml mtr>}} |
| 4795 |
\Configure{smallmatrix} |
| 4796 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="smallmatrix">}} |
| 4797 |
{\HCode{</\a:mathml mtable>}} |
| 4798 |
{\HCode{<\a:mathml mtr>}} |
| 4799 |
{\HCode{</\a:mathml mtr>}} |
| 4800 |
{\HCode{<\a:mathml mtd\Hnewline>}} |
| 4801 |
{\HCode{</\a:mathml mtd>}} |
| 4802 |
>>> |
| 4803 |
|
| 4804 |
\<amstex.tex mathml\><<< |
| 4805 |
\Configure{matrix} |
| 4806 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="matrix">}} |
| 4807 |
{\HCode{</\a:mathml mtable>}} |
| 4808 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4809 |
{\HCode{|<mtd matrix|>}} {\HCode{</\a:mathml mtd>}} |
| 4810 |
>>> |
| 4811 |
|
| 4812 |
\<amstex.tex mathml\><<< |
| 4813 |
\Configure{pmatrix}{\Tg<\a:mathml mrow \mml:class="pmatrix">} |
| 4814 |
{\Tg</\a:mathml mrow>} |
| 4815 |
>>> |
| 4816 |
|
| 4817 |
\<amstex.tex mathml\><<< |
| 4818 |
\Configure{align} |
| 4819 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="align">}} |
| 4820 |
{\HCode{</\a:mathml mtable>}} |
| 4821 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4822 |
{\HCode{<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 4823 |
\Configure{aligned} |
| 4824 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="aligned">}} |
| 4825 |
{\HCode{</\a:mathml mtable>}} |
| 4826 |
{\HCode{<\a:mathml mtr\Hnewline>}} {\HCode{</\a:mathml mtr>}} |
| 4827 |
{\HCode{<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 4828 |
>>> |
| 4829 |
|
| 4830 |
\<amstex.tex mathml\><<< |
| 4831 |
\Configure{cases} |
| 4832 |
{\Tg<\a:mathml mrow \mml:class="cases">} |
| 4833 |
{\Tg</\a:mathml mrow>} |
| 4834 |
\Configure{alignat} |
| 4835 |
{\HCode{<\a:mathml mtable \mml:class="alignat">}} |
| 4836 |
{\HCode{</\a:mathml mtable>}} |
| 4837 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="alignat">}} |
| 4838 |
{\HCode{</\a:mathml mtr>}} |
| 4839 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="alignat">}} |
| 4840 |
{\HCode{</\a:mathml mtd>}} |
| 4841 |
\Configure{gather} |
| 4842 |
{\HCode{<\a:mathml mtable \mml:class="gather">}} |
| 4843 |
{\HCode{</\a:mathml mtable>}} |
| 4844 |
{\HCode{<\a:mathml mtr\Hnewline \mml:class="gather">}} |
| 4845 |
{\HCode{</\a:mathml mtr>}} |
| 4846 |
{\HCode{<\a:mathml mtd\Hnewline \mml:class="gather">}} |
| 4847 |
{\HCode{</\a:mathml mtd>}} |
| 4848 |
>>>> |
| 4849 |
|
| 4850 |
\<vanilla mathml\><<< |
| 4851 |
\Configure{align} |
| 4852 |
{\EndP\HCode{<\a:mathml mtable\Hnewline \mml:class="align">}} |
| 4853 |
{\HCode{</\a:mathml mtable>}} |
| 4854 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 4855 |
{\HCode{<\a:mathml mtd>}} {\HCode{</\a:mathml mtd>}} |
| 4856 |
>>> |
| 4857 |
|
| 4858 |
|
| 4859 |
|
| 4860 |
|
| 4861 |
|
| 4862 |
|
| 4863 |
|
| 4864 |
% {\mathchar"0403} % \square |
| 4865 |
% {\mathchar"0404} % \blacksquare |
| 4866 |
% {\mathchar"0406} % \lozenge |
| 4867 |
% {\mathchar"0407} % \blacklozenge |
| 4868 |
% {\mathchar"0438} % \backprime |
| 4869 |
% {\mathchar"0446} % \bigstar |
| 4870 |
% {\mathchar"0448} % \blacktriangledown |
| 4871 |
% {\mathchar"044E} % \blacktriangle |
| 4872 |
% {\mathchar"044F} % \triangledown |
| 4873 |
% {\mathchar"045D} % \measuredangle |
| 4874 |
% {\mathchar"045E} % \sphericalangle |
| 4875 |
% {\mathchar"0473} % \circledS |
| 4876 |
% {\mathchar"047B} % \complement |
| 4877 |
% {\mathchar"051E} % \diagup |
| 4878 |
% {\mathchar"051F} % \diagdown |
| 4879 |
% {\mathchar"053F} % \varnothing |
| 4880 |
% {\mathchar"0540} % \nexists |
| 4881 |
% {\mathchar"0560} % \Finv |
| 4882 |
% {\mathchar"0561} % \Game |
| 4883 |
% {\mathchar"0567} % \eth |
| 4884 |
% {\mathchar"0569} % \beth |
| 4885 |
% {\mathchar"056A} % \gimel |
| 4886 |
% {\mathchar"056B} % \daleth |
| 4887 |
% {\mathchar"057A} % \digamma |
| 4888 |
% {\mathchar"057B} % \varkappa |
| 4889 |
% {\mathchar"057C} % \Bbbk |
| 4890 |
% {\mathchar"057D} % \hslash |
| 4891 |
|
| 4892 |
|
| 4893 |
|
| 4894 |
|
| 4895 |
|
| 4896 |
|
| 4897 |
|
| 4898 |
\<math fonts utilities\><<< |
| 4899 |
\ifx \tmp:bx\:UnDef \csname newbox\endcsname \tmp:bx \fi |
| 4900 |
\ifx \find:set:mgroup\:UnDef |
| 4901 |
\def\find:set:mgroup#1#2#3{\bgroup |
| 4902 |
\def\use@mathgroup##1##2##3{\relax |
| 4903 |
\tmp:cnt=##2% |
| 4904 |
\xdef\:temp####1{\noexpand\Configure{MathClass}{#2}% |
| 4905 |
{}{}{}{\mathchar"0\the\tmp:cnt ####1}}% |
| 4906 |
}% |
| 4907 |
\setbox\tmp:bx=\hbox{$#1$}\setbox\tmp:bx=\hbox{}% |
| 4908 |
\set:mgroup#3{}{}% |
| 4909 |
\egroup |
| 4910 |
} |
| 4911 |
\fi |
| 4912 |
\def\set:mgroup#1#2{\if :#1#2:\else |
| 4913 |
\:temp{#1#2}\expandafter\set:mgroup \fi} |
| 4914 |
>>> |
| 4915 |
|
| 4916 |
|
| 4917 |
|
| 4918 |
\<set mathcal class\><<< |
| 4919 |
\ifx \mathboldcalMathClass\:UnDef |
| 4920 |
\NewMathClass\mathboldcalMathClass |
| 4921 |
\fi |
| 4922 |
\Configure{MathClass}{\mathboldcalMathClass}{*} |
| 4923 |
{<\a:mathml mi\Hnewline |
| 4924 |
mathvariant="bold-script">}{</\a:mathml mi>}{} |
| 4925 |
>>> |
| 4926 |
|
| 4927 |
\<set mathcal symbols\><<< |
| 4928 |
\expandafter\ifx\csname mv@bold\endcsname\relax \else |
| 4929 |
\bgroup |
| 4930 |
\mathversion{bold}% |
| 4931 |
\find:set:mgroup{\mathcal{A}}{\mathboldcalMathClass}% |
| 4932 |
{4142434445464748494A4B4C4D4E4F505152535455565758595A} |%A--Z|% |
| 4933 |
\egroup |
| 4934 |
\fi |
| 4935 |
>>> |
| 4936 |
|
| 4937 |
This version of mathcal will prevent conversion of letters to Unicode Script values. |
| 4938 |
The Script style is required using the mathvariant attribute, so it should be |
| 4939 |
rendered correctly. |
| 4940 |
|
| 4941 |
\<redefine mathcal\><<< |
| 4942 |
\def\:tempa#1{\bgroup\HCode{<\a:mathml mstyle\Hnewline mathvariant="script">}#1\HCode{</\a:mathml mstyle>}\egroup} |
| 4943 |
\HLet\mathcal\:tempa |
| 4944 |
>>> |
| 4945 |
|
| 4946 |
|
| 4947 |
\<configure mathml amssymb\><<< |
| 4948 |
\def\:tempa#1"#2#3///{% |
| 4949 |
\edef\:next{\noexpand\Configure{MathClass}{\ifnum 0=#2 |
| 4950 |
\mathordMathClass \else #2\fi}}% |
| 4951 |
\:next |
| 4952 |
} |
| 4953 |
% \def\:tempb#1{\:tempa#1///{}{}{}{#1}} |
| 4954 |
% \def\:tempc#1"#2//{\:tempb{\mathchar"#2}} |
| 4955 |
% \def\:temp#1{\expandafter\:tempc\meaning#1//} |
| 4956 |
\def\:temp#1{\expandafter\:tempc\meaning#1//} |
| 4957 |
\def\:tempb#1{\:tempa#1///{}{}{}{#1}} |
| 4958 |
\def\:tempc#1"#2//{\:tempd#2...//} |
| 4959 |
\def\:tempd#1#2#3#4#5//{% |
| 4960 |
\if #4.\:tempb{\mathchar"0#1#2#3}\else |
| 4961 |
\:tempb{\mathchar"#1#2#3#4}\fi |
| 4962 |
} |
| 4963 |
\:temp \boxdot |
| 4964 |
\:temp \boxplus |
| 4965 |
\:temp \boxtimes |
| 4966 |
\:temp \centerdot |
| 4967 |
\:temp \boxminus |
| 4968 |
\:temp \veebar |
| 4969 |
\:temp \barwedge |
| 4970 |
\:temp \doublebarwedge |
| 4971 |
\:temp \Cup |
| 4972 |
\:temp \Cap |
| 4973 |
\:temp \curlywedge |
| 4974 |
\:temp \curlyvee |
| 4975 |
\:temp \leftthreetimes |
| 4976 |
\:temp \rightthreetimes |
| 4977 |
\:temp \dotplus |
| 4978 |
\:temp \intercal |
| 4979 |
\:temp \circledcirc |
| 4980 |
\:temp \circledast |
| 4981 |
\:temp \circleddash |
| 4982 |
\:temp \divideontimes |
| 4983 |
\:temp \lessdot |
| 4984 |
\:temp \gtrdot |
| 4985 |
\:temp \ltimes |
| 4986 |
\:temp \rtimes |
| 4987 |
\:temp \smallsetminus |
| 4988 |
\:temp \circlearrowright |
| 4989 |
\:temp \circlearrowleft |
| 4990 |
\:temp \leftrightharpoons |
| 4991 |
\:temp \Vdash |
| 4992 |
\:temp \Vvdash |
| 4993 |
\:temp \vDash |
| 4994 |
\:temp \twoheadrightarrow |
| 4995 |
\:temp \twoheadleftarrow |
| 4996 |
\:temp \leftleftarrows |
| 4997 |
\:temp \rightrightarrows |
| 4998 |
\:temp \upuparrows |
| 4999 |
\:temp \downdownarrows |
| 5000 |
\:temp \upharpoonright |
| 5001 |
\:temp \downharpoonright |
| 5002 |
\:temp \upharpoonleft |
| 5003 |
\:temp \downharpoonleft |
| 5004 |
\:temp \rightarrowtail |
| 5005 |
\:temp \leftarrowtail |
| 5006 |
\:temp \leftrightarrows |
| 5007 |
\:temp \rightleftarrows |
| 5008 |
\:temp \Lsh |
| 5009 |
\:temp \Rsh |
| 5010 |
\:temp \rightsquigarrow |
| 5011 |
\:temp \leftrightsquigarrow |
| 5012 |
\:temp \looparrowleft |
| 5013 |
\:temp \looparrowright |
| 5014 |
\:temp \circeq |
| 5015 |
\:temp \succsim |
| 5016 |
\:temp \gtrsim |
| 5017 |
\:temp \gtrapprox |
| 5018 |
\:temp \multimap |
| 5019 |
\:temp \therefore |
| 5020 |
\:temp \because |
| 5021 |
\:temp \doteqdot |
| 5022 |
\:temp \triangleq |
| 5023 |
\:temp \precsim |
| 5024 |
\:temp \lesssim |
| 5025 |
\:temp \lessapprox |
| 5026 |
\:temp \eqslantless |
| 5027 |
\:temp \eqslantgtr |
| 5028 |
\:temp \curlyeqprec |
| 5029 |
\:temp \curlyeqsucc |
| 5030 |
\:temp \preccurlyeq |
| 5031 |
\:temp \leqq |
| 5032 |
\:temp \leqslant |
| 5033 |
\:temp \lessgtr |
| 5034 |
\:temp \risingdotseq |
| 5035 |
\:temp \fallingdotseq |
| 5036 |
\:temp \succcurlyeq |
| 5037 |
\:temp \geqq |
| 5038 |
\:temp \geqslant |
| 5039 |
\:temp \gtrless |
| 5040 |
\:temp \vartriangleright |
| 5041 |
\:temp \vartriangleleft |
| 5042 |
\:temp \trianglerighteq |
| 5043 |
\:temp \trianglelefteq |
| 5044 |
\:temp \between |
| 5045 |
\:temp \blacktriangleright |
| 5046 |
\:temp \blacktriangleleft |
| 5047 |
\:temp \vartriangle |
| 5048 |
\:temp \eqcirc |
| 5049 |
\:temp \lesseqgtr |
| 5050 |
\:temp \gtreqless |
| 5051 |
\:temp \lesseqqgtr |
| 5052 |
\:temp \gtreqqless |
| 5053 |
\:temp \Rrightarrow |
| 5054 |
\:temp \Lleftarrow |
| 5055 |
\:temp \varpropto |
| 5056 |
\:temp \smallsmile |
| 5057 |
\:temp \smallfrown |
| 5058 |
\:temp \Subset |
| 5059 |
\:temp \Supset |
| 5060 |
\:temp \subseteqq |
| 5061 |
\:temp \supseteqq |
| 5062 |
\:temp \bumpeq |
| 5063 |
\:temp \Bumpeq |
| 5064 |
\:temp \lll |
| 5065 |
\:temp \ggg |
| 5066 |
\:temp \pitchfork |
| 5067 |
\:temp \backsim |
| 5068 |
\:temp \backsimeq |
| 5069 |
\:temp \lvertneqq |
| 5070 |
\:temp \gvertneqq |
| 5071 |
\:temp \nleq |
| 5072 |
\:temp \ngeq |
| 5073 |
\:temp \nless |
| 5074 |
\:temp \ngtr |
| 5075 |
\:temp \nprec |
| 5076 |
\:temp \nsucc |
| 5077 |
\:temp \lneqq |
| 5078 |
\:temp \gneqq |
| 5079 |
\:temp \nleqslant |
| 5080 |
\:temp \ngeqslant |
| 5081 |
\@ifpackageloaded{program}{}{\:temp \lneq} |
| 5082 |
\:temp \gneq |
| 5083 |
\:temp \npreceq |
| 5084 |
\:temp \nsucceq |
| 5085 |
\:temp \precnsim |
| 5086 |
\:temp \succnsim |
| 5087 |
\:temp \lnsim |
| 5088 |
\:temp \gnsim |
| 5089 |
\:temp \nleqq |
| 5090 |
\:temp \ngeqq |
| 5091 |
\:temp \precneqq |
| 5092 |
\:temp \succneqq |
| 5093 |
\:temp \precnapprox |
| 5094 |
\:temp \succnapprox |
| 5095 |
\:temp \lnapprox |
| 5096 |
\:temp \gnapprox |
| 5097 |
\:temp \nsim |
| 5098 |
\:temp \ncong |
| 5099 |
\:temp \varsubsetneq |
| 5100 |
\:temp \varsupsetneq |
| 5101 |
\:temp \nsubseteqq |
| 5102 |
\:temp \nsupseteqq |
| 5103 |
\:temp \subsetneqq |
| 5104 |
\:temp \supsetneqq |
| 5105 |
\:temp \varsubsetneqq |
| 5106 |
\:temp \varsupsetneqq |
| 5107 |
\:temp \subsetneq |
| 5108 |
\:temp \supsetneq |
| 5109 |
\:temp \nsubseteq |
| 5110 |
\:temp \nsupseteq |
| 5111 |
\:temp \nparallel |
| 5112 |
\:temp \nmid |
| 5113 |
\:temp \nshortmid |
| 5114 |
\:temp \nshortparallel |
| 5115 |
\:temp \nvdash |
| 5116 |
\:temp \nVdash |
| 5117 |
\:temp \nvDash |
| 5118 |
\:temp \nVDash |
| 5119 |
\:temp \ntrianglerighteq |
| 5120 |
\:temp \ntrianglelefteq |
| 5121 |
\:temp \ntriangleleft |
| 5122 |
\:temp \ntriangleright |
| 5123 |
\:temp \nleftarrow |
| 5124 |
\:temp \nrightarrow |
| 5125 |
\:temp \nLeftarrow |
| 5126 |
\:temp \nRightarrow |
| 5127 |
\:temp \nLeftrightarrow |
| 5128 |
\:temp \nleftrightarrow |
| 5129 |
\:temp \eqsim |
| 5130 |
\:temp \shortmid |
| 5131 |
\:temp \shortparallel |
| 5132 |
\:temp \thicksim |
| 5133 |
\:temp \thickapprox |
| 5134 |
\:temp \approxeq |
| 5135 |
\:temp \succapprox |
| 5136 |
\:temp \precapprox |
| 5137 |
\:temp \curvearrowleft |
| 5138 |
\:temp \curvearrowright |
| 5139 |
\:temp \backepsilon |
| 5140 |
\:temp \square |
| 5141 |
\:temp \blacksquare |
| 5142 |
\:temp \lozenge |
| 5143 |
\:temp \blacklozenge |
| 5144 |
\:temp \backprime |
| 5145 |
\:temp \bigstar |
| 5146 |
\:temp \blacktriangledown |
| 5147 |
\:temp \blacktriangle |
| 5148 |
\:temp \triangledown |
| 5149 |
\:temp \measuredangle |
| 5150 |
\:temp \sphericalangle |
| 5151 |
\:temp \circledS |
| 5152 |
\:temp \complement |
| 5153 |
\:temp \diagup |
| 5154 |
\:temp \diagdown |
| 5155 |
\:temp \varnothing |
| 5156 |
\:temp \nexists |
| 5157 |
\:temp \Finv |
| 5158 |
\:temp \Game |
| 5159 |
\:temp \eth |
| 5160 |
\:temp \beth |
| 5161 |
\:temp \gimel |
| 5162 |
\:temp \daleth |
| 5163 |
\:temp \digamma |
| 5164 |
\:temp \varkappa |
| 5165 |
\:temp \Bbbk |
| 5166 |
\:temp \hslash |
| 5167 |
>>> |
| 5168 |
|
| 5169 |
Note that in the presence of bm.sty the symbols of amssymb change their |
| 5170 |
codings. |
| 5171 |
|
| 5172 |
\begin{verbatim} |
| 5173 |
\documentclass{article} |
| 5174 |
% \usepackage{bm} |
| 5175 |
\usepackage{amsmath,amssymb} |
| 5176 |
\begin{document} |
| 5177 |
\hshow{boxdot} |
| 5178 |
\begin{equation} |
| 5179 |
2 |
| 5180 |
\end{equation} |
| 5181 |
\end{document} |
| 5182 |
\end{verbatim} |
| 5183 |
|
| 5184 |
|
| 5185 |
%%%%%%%%%%%%%%%%%% |
| 5186 |
\chapter{Loose Ends} |
| 5187 |
%%%%%%%%%%%%%%%%%% |
| 5188 |
|
| 5189 |
%%%%%%%%%%%%%%%%%% |
| 5190 |
\section{Commutative Diagrams (amscd)} |
| 5191 |
%%%%%%%%%%%%%%%%%% |
| 5192 |
|
| 5193 |
|
| 5194 |
|
| 5195 |
\<configure mathml amscd\><<< |
| 5196 |
\ConfigureEnv{CD}{}{}{}{} |
| 5197 |
\Configure{CD} |
| 5198 |
{\HCode{<\a:mathml mtable class="CD"\Hnewline>}} |
| 5199 |
{\HCode{</\a:mathml mtable>}} |
| 5200 |
{\HCode{<\a:mathml mtr>}} |
| 5201 |
{\HCode{</\a:mathml mtr>}} |
| 5202 |
{\HCode{<\a:mathml mtd\Hnewline>}} |
| 5203 |
{\HCode{</\a:mathml mtd>}} |
| 5204 |
>>> |
| 5205 |
|
| 5206 |
|
| 5207 |
|
| 5208 |
|
| 5209 |
\<configure mathml amscd\><<< |
| 5210 |
\Configure{ @>} |
| 5211 |
{\Configure{mathrel*}{*} |
| 5212 |
{<mrow \mml:class="rightarrow" >} |
| 5213 |
{</mrow>} |
| 5214 |
{}} |
| 5215 |
>>> |
| 5216 |
|
| 5217 |
|
| 5218 |
\<configure mathml amscd\><<< |
| 5219 |
\Configure{ @<} |
| 5220 |
{\Configure{mathrel*}{*} |
| 5221 |
{<mrow \mml:class="leftarrow" >} |
| 5222 |
{</mrow>} |
| 5223 |
{}} |
| 5224 |
>>> |
| 5225 |
|
| 5226 |
\<configure mathml amscd\><<< |
| 5227 |
\Configure{ @V} |
| 5228 |
{\HCode{<mphantom>} |
| 5229 |
\hbox{$\m@th\vcenter{\hbox{$\scriptstyle#2$}}$}%% |
| 5230 |
\HCode{</mphantom>}} |
| 5231 |
{\HCode{<mphantom>} |
| 5232 |
\hbox{$\m@th\vcenter{\hbox{$\m@th\vcenter{\hbox |
| 5233 |
{$\scriptstyle#1$}}$}}$}% |
| 5234 |
\HCode{</mphantom>}} |
| 5235 |
>>> |
| 5236 |
|
| 5237 |
Are there \verb+\llap+and \verb+\rlap+ facilities in mathml? |
| 5238 |
|
| 5239 |
%%%%%%%%%%%%%%%%%% |
| 5240 |
\section{Right-to-Left Babel} |
| 5241 |
%%%%%%%%%%%%%%%%%% |
| 5242 |
|
| 5243 |
|
| 5244 |
|
| 5245 |
\<rlbabel everypar\><<< |
| 5246 |
\expandafter\ifx \csname o@everypar\endcsname\relax \else |
| 5247 |
\expandafter\ifx \csname ht:everypar\endcsname\relax |
| 5248 |
\let\ht:everypar\o@everypar |
| 5249 |
\fi\fi |
| 5250 |
>>> |
| 5251 |
|
| 5252 |
|
| 5253 |
|
| 5254 |
|
| 5255 |
|
| 5256 |
|
| 5257 |
\<dir ltr/rtl\><<< |
| 5258 |
dir="\if@rl rtl\else ltr\fi" |
| 5259 |
>>> |
| 5260 |
|
| 5261 |
|
| 5262 |
\<configure html-mml rlbabel\><<< |
| 5263 |
\Configure{moreL} |
| 5264 |
{\ifmathml |<ltr rlbabel mtext|>% |
| 5265 |
\else |
| 5266 |
\ifvmode \let\end:moreRL=\empty |
| 5267 |
\else\HCode{<span dir="ltr" >}% |
| 5268 |
\def\end:moreRL{\HCode{</span>}}% |
| 5269 |
\fi |
| 5270 |
\fi |
| 5271 |
} |
| 5272 |
{\end:moreRL} |
| 5273 |
\Configure{moreR} |
| 5274 |
{\ifmathml |<rtl rlbabel mtext|>% |
| 5275 |
\else |
| 5276 |
\ifvmode \let\end:moreRL=\empty |
| 5277 |
\else\HCode{<span dir="rtl" >}\def\end:moreRL{\HCode{</span>}}\fi |
| 5278 |
\fi |
| 5279 |
} |
| 5280 |
{\end:moreRL} |
| 5281 |
\Css{.rtl {direction: rtl} |
| 5282 |
.ltr {direction: ltr} } |
| 5283 |
>>> |
| 5284 |
|
| 5285 |
|
| 5286 |
|
| 5287 |
\<ltr rlbabel mtext\><<< |
| 5288 |
\ifmtext |
| 5289 |
\leavevmode\special{t4ht@+</\a:mathml mtext><\a:mathml mtext{32}\mml:class="ltr">}x% |
| 5290 |
\def\end:moreRL{\HCode{</\a:mathml mtext><\a:mathml mtext>}}% |
| 5291 |
\else |
| 5292 |
\let\end:moreRL=\empty |
| 5293 |
\fi |
| 5294 |
>>> |
| 5295 |
|
| 5296 |
|
| 5297 |
|
| 5298 |
\<rtl rlbabel mtext\><<< |
| 5299 |
\ifmtext |
| 5300 |
\leavevmode\special{t4ht@+</\a:mathml mtext><\a:mathml mtext{32}\mml:class="rtl">}x% |
| 5301 |
\def\end:moreRL{\HCode{</\a:mathml mtext><\a:mathml mtext>}}% |
| 5302 |
\else |
| 5303 |
\let\end:moreRL=\empty |
| 5304 |
\fi |
| 5305 |
>>> |
| 5306 |
|
| 5307 |
|
| 5308 |
%%%%%%%%%%%%% |
| 5309 |
\subsection{Tables} |
| 5310 |
%%%%%%%%%%%%% |
| 5311 |
|
| 5312 |
|
| 5313 |
%%%%%%%%%%%%% |
| 5314 |
\subsection{dcolumn} |
| 5315 |
%%%%%%%%%%%%% |
| 5316 |
|
| 5317 |
|
| 5318 |
\<configure mathml dcolumn\><<< |
| 5319 |
\Configure{dcolumn} |
| 5320 |
{\NoFonts\Configure{$}{}{}{}} |
| 5321 |
{\EndNoFonts} |
| 5322 |
>>> |
| 5323 |
|
| 5324 |
|
| 5325 |
|
| 5326 |
|
| 5327 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5328 |
\section{openmath} |
| 5329 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5330 |
|
| 5331 |
|
| 5332 |
\<itemitem 0.0\><<< |
| 5333 |
\Configure{itemitem}{}{}{\par\leavevmode}{} |
| 5334 |
>>> |
| 5335 |
|
| 5336 |
|
| 5337 |
|
| 5338 |
|
| 5339 |
Used to have also a \verb'\special{t4ht@[}...\special{t4ht@]}', |
| 5340 |
where the specials asked to igore the enclosed |
| 5341 |
content. It is provided for getting `realistic' measurements in mathml |
| 5342 |
applets. a candidadte for delition. |
| 5343 |
|
| 5344 |
|
| 5345 |
|
| 5346 |
|
| 5347 |
|
| 5348 |
|
| 5349 |
|
| 5350 |
|
| 5351 |
|
| 5352 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5353 |
\chapter{Shared} |
| 5354 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5355 |
|
| 5356 |
|
| 5357 |
\<par del\><<< |
| 5358 |
!*?: >>> |
| 5359 |
|
| 5360 |
|
| 5361 |
\<tag of Tag\><<< |
| 5362 |
cw:>>> |
| 5363 |
|
| 5364 |
\<tail\><<< |
| 5365 |
tail>>> |
| 5366 |
|
| 5367 |
\<addr for Tag and Ref of Sec\><<< |
| 5368 |
\xdef\:cursec{|<section html addr|>}% |
| 5369 |
>>> |
| 5370 |
|
| 5371 |
|
| 5372 |
\<save catcodes\><<< |
| 5373 |
\expandafter\edef\csname :RestoreCatcodes\endcsname{% |
| 5374 |
\expandafter\ifx \csname :RestoreCatcodes\endcsname\relax\else |
| 5375 |
\csname :RestoreCatcodes\endcsname \fi |
| 5376 |
\catcode`\noexpand :|=\the\catcode`:% |
| 5377 |
\let\expandafter\noexpand\csname :RestoreCatcodes\endcsname|= |
| 5378 |
\noexpand\UnDefcS} |
| 5379 |
\catcode`\:|=11 |
| 5380 |
>>> |
| 5381 |
|
| 5382 |
|
| 5383 |
|
| 5384 |
|
| 5385 |
|
| 5386 |
|
| 5387 |
%%%%%%%%%%%%%%%%%% |
| 5388 |
\section{Boxed} |
| 5389 |
%%%%%%%%%%%%%%%%%% |
| 5390 |
|
| 5391 |
\<configure mathml amsmath\><<< |
| 5392 |
\Configure{boxed} |
| 5393 |
{\ifmathml \Tg<\a:mathml menclose \a:mathml notation="box">\Tg<\a:mathml mrow>% |
| 5394 |
\else \HCode{<span class="boxed">}\fi\IgnorePar} |
| 5395 |
{\ifmathml \Tg</\a:mathml mrow>\Tg</\a:mathml menclose>% |
| 5396 |
\else \HCode{</span>}\fi} |
| 5397 |
\Css{.boxed{border: 1px solid black; padding-left:2px; |
| 5398 |
padding-right:2px;}} |
| 5399 |
>>> |
| 5400 |
|
| 5401 |
%%%%%%%%%%%%%%%%%% |
| 5402 |
\section{fontmath} |
| 5403 |
%%%%%%%%%%%%%%%%%% |
| 5404 |
|
| 5405 |
|
| 5406 |
|
| 5407 |
|
| 5408 |
\<fontmath mathord symbols as ?\><<< |
| 5409 |
\mathchar"3230 |%\prime|% |
| 5410 |
\mathchar"3231 |%\infty|% |
| 5411 |
\mathchar"323B |%\emptyset|% |
| 5412 |
\mathchar"323C |%\Re|% |
| 5413 |
\mathchar"323D |%\Im|% |
| 5414 |
\mathchar"3240 |%\aleph|% |
| 5415 |
>>> |
| 5416 |
|
| 5417 |
\<fontmath mathord symbols as op\><<< |
| 5418 |
\mathchar"3234 |%\triangle|% |
| 5419 |
\mathchar"3238 |%\forall|% |
| 5420 |
\mathchar"3239 |%\exists|% |
| 5421 |
\mathchar"323A |%\neg|% |
| 5422 |
\mathchar"323E |%\top|% |
| 5423 |
\mathchar"323F |%\bot|% |
| 5424 |
\mathchar"3272 |%\nabla|% |
| 5425 |
\mathchar"3278 |%\mathsection|% |
| 5426 |
\mathchar"327B |%\mathparagraph|% |
| 5427 |
\mathchar"327C |%\clubsuit|% |
| 5428 |
\mathchar"327D |%\diamondsuit|% |
| 5429 |
\mathchar"327E |%\heartsuit|% |
| 5430 |
\mathchar"327F |%\spadesuit|% |
| 5431 |
>>> |
| 5432 |
|
| 5433 |
|
| 5434 |
|
| 5435 |
\subsection{1: Large Operators} |
| 5436 |
|
| 5437 |
\begin{verbatim} |
| 5438 |
\mathchardef\coprod="1360 |
| 5439 |
\mathchardef\bigvee="1357 |
| 5440 |
\mathchardef\bigwedge="1356 |
| 5441 |
\mathchardef\biguplus="1355 |
| 5442 |
\mathchardef\bigcap="1354 |
| 5443 |
\mathchardef\bigcup="1353 |
| 5444 |
\mathchardef\intop="1352 \def\int{\intop\nolimits} |
| 5445 |
\mathchardef\prod="1351 |
| 5446 |
\mathchardef\sum="1350 |
| 5447 |
\mathchardef\bigotimes="134E |
| 5448 |
\mathchardef\bigoplus="134C |
| 5449 |
\mathchardef\bigodot="134A |
| 5450 |
\mathchardef\ointop="1348 \def\oint{\ointop\nolimits} |
| 5451 |
\mathchardef\bigsqcup="1346 |
| 5452 |
\mathchardef\smallint="1273 |
| 5453 |
\end{verbatim} |
| 5454 |
|
| 5455 |
\<plain,fontmath math classes\><<< |
| 5456 |
\Configure{MathClass}{1}{}{}{}{ |
| 5457 |
\mathchar"1360 |
| 5458 |
\mathchar"1357 |
| 5459 |
\mathchar"1356 |
| 5460 |
\mathchar"1355 |
| 5461 |
\mathchar"1354 |
| 5462 |
\mathchar"1353 |
| 5463 |
\mathchar"1352 |
| 5464 |
\mathchar"1351 |
| 5465 |
\mathchar"1350 |
| 5466 |
\mathchar"134E |
| 5467 |
\mathchar"134C |
| 5468 |
\mathchar"134A |
| 5469 |
\mathchar"1348 |
| 5470 |
\mathchar"1346 |
| 5471 |
\mathchar"1273 |
| 5472 |
|<fontmath mathord symbols as op|>% |
| 5473 |
} |
| 5474 |
>>> |
| 5475 |
|
| 5476 |
% \mathchar"230 |%math prime|% |
| 5477 |
|
| 5478 |
A prime is typically placed on letters and digits. |
| 5479 |
|
| 5480 |
|
| 5481 |
\subsection{2: Binary Operations} |
| 5482 |
|
| 5483 |
\begin{verbatim} |
| 5484 |
\mathchardef\triangleleft="212F |
| 5485 |
\mathchardef\triangleright="212E |
| 5486 |
\mathchardef\bigtriangleup="2234 |
| 5487 |
\mathchardef\bigtriangledown="2235 |
| 5488 |
\mathchardef\wedge="225E \let\land=\wedge |
| 5489 |
\mathchardef\vee="225F \let\lor=\vee |
| 5490 |
\mathchardef\cap="225C |
| 5491 |
\mathchardef\cup="225B |
| 5492 |
\mathchardef\ddagger="227A |
| 5493 |
\mathchardef\dagger="2279 |
| 5494 |
\mathchardef\sqcap="2275 |
| 5495 |
\mathchardef\sqcup="2274 |
| 5496 |
\mathchardef\uplus="225D |
| 5497 |
\mathchardef\amalg="2271 |
| 5498 |
\mathchardef\diamond="2205 |
| 5499 |
\mathchardef\bullet="220F |
| 5500 |
\mathchardef\wr="226F |
| 5501 |
\mathchardef\div="2204 |
| 5502 |
\mathchardef\odot="220C |
| 5503 |
\mathchardef\oslash="220B |
| 5504 |
\mathchardef\otimes="220A |
| 5505 |
\mathchardef\ominus="2209 |
| 5506 |
\mathchardef\oplus="2208 |
| 5507 |
\mathchardef\mp="2207 |
| 5508 |
\mathchardef\pm="2206 |
| 5509 |
\mathchardef\circ="220E |
| 5510 |
\mathchardef\bigcirc="220D |
| 5511 |
\mathchardef\setminus="226E % for set difference A\setminus B |
| 5512 |
\mathchardef\cdot="2201 |
| 5513 |
\mathchardef\ast="2203 |
| 5514 |
\mathchardef\times="2202 |
| 5515 |
\mathchardef\star="213F |
| 5516 |
\mathcode`\*="2203 % \ast |
| 5517 |
\mathcode`\+="202B |
| 5518 |
\mathcode`\-="2200 |
| 5519 |
\end{verbatim} |
| 5520 |
|
| 5521 |
\<plain,fontmath math classes\><<< |
| 5522 |
\Configure{MathClass}{2}{}{}{}{ |
| 5523 |
*-+/ |
| 5524 |
\mathchar"212F |
| 5525 |
\mathchar"212E |
| 5526 |
\mathchar"2234 |
| 5527 |
\mathchar"2235 |
| 5528 |
\mathchar"225E |
| 5529 |
\mathchar"225F |
| 5530 |
\mathchar"225C |
| 5531 |
\mathchar"225B |
| 5532 |
\mathchar"227A |
| 5533 |
\mathchar"2279 |
| 5534 |
\mathchar"2275 |
| 5535 |
\mathchar"2274 |
| 5536 |
\mathchar"225D |
| 5537 |
\mathchar"2271 |
| 5538 |
\mathchar"2205 |
| 5539 |
\mathchar"220F |
| 5540 |
\mathchar"226F |
| 5541 |
\mathchar"2204 |
| 5542 |
\mathchar"220C |
| 5543 |
\mathchar"220B |
| 5544 |
\mathchar"220A |
| 5545 |
\mathchar"2209 |
| 5546 |
\mathchar"2208 |
| 5547 |
\mathchar"2207 |
| 5548 |
\mathchar"2206 |
| 5549 |
\mathchar"220E |
| 5550 |
\mathchar"220D |
| 5551 |
\mathchar"226E |
| 5552 |
\mathchar"2201 |
| 5553 |
\mathchar"2203 |
| 5554 |
\mathchar"2202 |
| 5555 |
\mathchar"213F |
| 5556 |
\mathchar"6201 % cdot |
| 5557 |
} |
| 5558 |
>>> |
| 5559 |
|
| 5560 |
|
| 5561 |
\subsection{3: Relational Operations} |
| 5562 |
|
| 5563 |
The catcode is needed because 303A is \verb':'. |
| 5564 |
|
| 5565 |
\<plain,fontmath math classes\><<< |
| 5566 |
\Configure{MathClass}{3}{}{}{}{ |
| 5567 |
\mathchar"3128 |
| 5568 |
\mathchar"3129 |
| 5569 |
\mathchar"312A |
| 5570 |
\mathchar"312B |
| 5571 |
\mathchar"315E |
| 5572 |
\mathchar"315F |
| 5573 |
\mathchar"3210 |
| 5574 |
\mathchar"3211 |
| 5575 |
\mathchar"3212 |
| 5576 |
\mathchar"3213 |
| 5577 |
\mathchar"3214 |
| 5578 |
\mathchar"3215 |
| 5579 |
\mathchar"3216 |
| 5580 |
\mathchar"3217 |
| 5581 |
\mathchar"3218 |
| 5582 |
\mathchar"3219 |
| 5583 |
\mathchar"321A |
| 5584 |
\mathchar"321B |
| 5585 |
\mathchar"321C |
| 5586 |
\mathchar"321D |
| 5587 |
\mathchar"321E |
| 5588 |
\mathchar"321F |
| 5589 |
\mathchar"3220 |
| 5590 |
\mathchar"3221 |
| 5591 |
\mathchar"3224 |
| 5592 |
\mathchar"3227 |
| 5593 |
\mathchar"3232 |
| 5594 |
\mathchar"3233 |
| 5595 |
\mathchar"3236 |
| 5596 |
\mathchar"3237 |
| 5597 |
\mathchar"323F |
| 5598 |
:=>< |
| 5599 |
\mathchar"322F |
| 5600 |
\mathchar"3276 |
| 5601 |
\mathchar"3277 |
| 5602 |
\mathchar"326B |
| 5603 |
\mathchar"326A |
| 5604 |
\mathchar"3261 |
| 5605 |
\mathchar"3260 |
| 5606 |
\mathchar"3225 |
| 5607 |
\mathchar"3226 |
| 5608 |
\mathchar"322D |
| 5609 |
\mathchar"322E |
| 5610 |
\mathchar"322C |
| 5611 |
\mathchar"3228 |
| 5612 |
\mathchar"3229 |
| 5613 |
} |
| 5614 |
>>> |
| 5615 |
|
| 5616 |
% \mathchar"327C |%clubsuit|% |
| 5617 |
% \mathchar"327D |%diamondsuit|% |
| 5618 |
% \mathchar"327E |%heartsuit|% |
| 5619 |
% \mathchar"327F |%spadesuit|% |
| 5620 |
|
| 5621 |
|
| 5622 |
|
| 5623 |
% \mathchar"340A % rightleftharpoons |
| 5624 |
% \mathchar"340B % leftrightharpoons |
| 5625 |
% |
| 5626 |
|
| 5627 |
\begin{verbatim} |
| 5628 |
\mathcode`\>="313E |
| 5629 |
\mathcode`\<="313C |
| 5630 |
\mathcode`\=="303D |
| 5631 |
\mathcode`\:="303A |
| 5632 |
\mathchardef\leq="3214 \let\le=\leq |
| 5633 |
\mathchardef\geq="3215 \let\ge=\geq |
| 5634 |
\mathchardef\succ="321F |
| 5635 |
\mathchardef\prec="321E |
| 5636 |
\mathchardef\approx="3219 |
| 5637 |
\mathchardef\succeq="3217 |
| 5638 |
\mathchardef\preceq="3216 |
| 5639 |
\mathchardef\supset="321B |
| 5640 |
\mathchardef\set="321A |
| 5641 |
\mathchardef\supseteq="3213 |
| 5642 |
\mathchardef\seteq="3212 |
| 5643 |
\mathchardef\in="3232 |
| 5644 |
\mathchardef\ni="3233 \let\owns=\ni |
| 5645 |
\mathchardef\gg="321D |
| 5646 |
\mathchardef\ll="321C |
| 5647 |
\mathchardef\not="3236 |
| 5648 |
\mathchardef\leftrightarrow="3224 |
| 5649 |
\mathchardef\leftarrow="3220 \let\gets=\leftarrow |
| 5650 |
\mathchardef\rightarrow="3221 \let\to=\rightarrow |
| 5651 |
\mathchardef\mapstochar="3237 \def\mapsto{\mapstochar\rightarrow} |
| 5652 |
\mathchardef\sim="3218 |
| 5653 |
\mathchardef\simeq="3227 |
| 5654 |
\mathchardef\perp="323F |
| 5655 |
\mathchardef\equiv="3211 |
| 5656 |
\mathchardef\asymp="3210 |
| 5657 |
\mathchardef\smile="315E |
| 5658 |
\mathchardef\frown="315F |
| 5659 |
\mathchardef\leftharpoonup="3128 |
| 5660 |
\mathchardef\leftharpoondown="3129 |
| 5661 |
\mathchardef\rightharpoonup="312A |
| 5662 |
\mathchardef\rightharpoondown="312B |
| 5663 |
\mathchardef\propto="322F |
| 5664 |
\mathchardef\sqsubseteq="3276 |
| 5665 |
\mathchardef\sqsupseteq="3277 |
| 5666 |
\mathchardef\parallel="326B |
| 5667 |
\mathchardef\mid="326A |
| 5668 |
\mathchardef\dashv="3261 |
| 5669 |
\mathchardef\vdash="3260 |
| 5670 |
\mathchardef\nearrow="3225 |
| 5671 |
\mathchardef\searrow="3226 |
| 5672 |
\mathchardef\nwarrow="322D |
| 5673 |
\mathchardef\swarrow="322E |
| 5674 |
\mathchardef\Leftrightarrow="322C |
| 5675 |
\mathchardef\Leftarrow="3228 |
| 5676 |
\mathchardef\Rightarrow="3229 |
| 5677 |
\end{verbatim} |
| 5678 |
|
| 5679 |
|
| 5680 |
\subsection{4/5: Delimiters} |
| 5681 |
|
| 5682 |
\begin{verbatim} |
| 5683 |
\mathcode`\(="4028 |
| 5684 |
\mathcode`\)="5029 |
| 5685 |
\mathcode`\[="405B |
| 5686 |
\mathcode`\]="505D |
| 5687 |
\mathcode`\{="4266 |
| 5688 |
\mathcode`\}="5267 |
| 5689 |
\delcode`\(="028300 |
| 5690 |
\delcode`\)="029301 |
| 5691 |
\delcode`\[="05B302 |
| 5692 |
\delcode`\]="05D303 |
| 5693 |
\def\lmoustache{\delimiter"437A340 } % top from (, bottom from ) |
| 5694 |
\def\rmoustache{\delimiter"537B341 } % top from ), bottom from ( |
| 5695 |
\def\lgroup{\delimiter"462833A } % extensible ( with sharper tips |
| 5696 |
\def\rgroup{\delimiter"562933B } % extensible ) with sharper tips |
| 5697 |
\def\backslash{\delimiter"26E30F } % for double coset G\backslash H |
| 5698 |
\def\rangle{\delimiter"526930B } |
| 5699 |
\def\langle{\delimiter"426830A } |
| 5700 |
\def\rbrace{\delimiter"5267309 } \let\}=\rbrace |
| 5701 |
\def\lbrace{\delimiter"4266308 } \let\{=\lbrace |
| 5702 |
\def\rceil{\delimiter"5265307 } |
| 5703 |
\def\lceil{\delimiter"4264306 } |
| 5704 |
\def\rfloor{\delimiter"5263305 } |
| 5705 |
\def\lfloor{\delimiter"4262304 } |
| 5706 |
\def\arrowvert{\delimiter"26A33C } % arrow without arrowheads |
| 5707 |
\def\Arrowvert{\delimiter"26B33D } % double arrow without arrowheads |
| 5708 |
\def\bracevert{\delimiter"77C33E } % the vertical bar that extends braces |
| 5709 |
\def\Vert{\delimiter"26B30D } \let\|=\Vert How should these be treated? |
| 5710 |
\def\vert{\delimiter"26A30C } " " " " " |
| 5711 |
\def\uparrow{\delimiter"3222378 } |
| 5712 |
\def\downarrow{\delimiter"3223379 } |
| 5713 |
\def\updownarrow{\delimiter"326C33F } |
| 5714 |
\def\Uparrow{\delimiter"322A37E } |
| 5715 |
\def\Downarrow{\delimiter"322B37F } |
| 5716 |
\def\Updownarrow{\delimiter"326D377 } |
| 5717 |
\end{verbatim} |
| 5718 |
|
| 5719 |
The comamnds \verb'\Configure{MathClass}{4}...' |
| 5720 |
and \verb'\Configure{MathClass}{5}...' |
| 5721 |
are for unmatched delimiters, and the comamnd |
| 5722 |
\verb'\Configure{MathDelimiters}{(}{)}' is for matched ones. |
| 5723 |
|
| 5724 |
|
| 5725 |
\<plain,fontmath math classes\><<< |
| 5726 |
\Configure{MathClass}{4}{}{}{}{} |
| 5727 |
\Configure{MathDelimiters}{(}{)} |
| 5728 |
\Configure{MathDelimiters}{[}{]} |
| 5729 |
\Configure{MathDelimiters}{\mathchar"4262}{\mathchar"5263} |
| 5730 |
\Configure{MathDelimiters}{\mathchar"4264}{\mathchar"5265} |
| 5731 |
\Configure{MathDelimiters}{\mathchar"4266}{\mathchar"5267} |
| 5732 |
\Configure{MathDelimiters}{\mathchar"4268}{\mathchar"5269} |
| 5733 |
\Configure{MathDelimiters}{\mathchar"4300}{\mathchar"5301} |
| 5734 |
\Configure{MathDelimiters}{\mathchar"4302}{\mathchar"5303} |
| 5735 |
\Configure{MathDelimiters}{\mathchar"4304}{\mathchar"5305} |
| 5736 |
\Configure{MathDelimiters}{\mathchar"4306}{\mathchar"5307} |
| 5737 |
\Configure{MathDelimiters}{\mathchar"4308}{\mathchar"5309} |
| 5738 |
\Configure{MathDelimiters}{\mathchar"430A}{\mathchar"530B} |
| 5739 |
>>> |
| 5740 |
|
| 5741 |
\begin{verbatim} |
| 5742 |
\mathcode`\?="503F |
| 5743 |
\end{verbatim} |
| 5744 |
|
| 5745 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5746 |
\subsection{6: Punctuation Marks} |
| 5747 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5748 |
|
| 5749 |
\begin{verbatim} |
| 5750 |
\mathcode`\;="603B |
| 5751 |
\mathcode`\,="613B |
| 5752 |
\end{verbatim} |
| 5753 |
|
| 5754 |
\<plain,fontmath math classes\><<< |
| 5755 |
\Configure{MathClass}{6}{}{}{}{ |
| 5756 |
\mathchar"613A % ldot |
| 5757 |
\mathchar"603A % colon |
| 5758 |
!?; , |
| 5759 |
} |
| 5760 |
>>> |
| 5761 |
|
| 5762 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5763 |
\subsection{Questions} |
| 5764 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5765 |
|
| 5766 |
\begin{verbatim} |
| 5767 |
|
| 5768 |
|
| 5769 |
\delcode`\<="26830A |
| 5770 |
\delcode`\>="26930B |
| 5771 |
\delcode`\|="26A30C |
| 5772 |
\delcode`\\="26E30F |
| 5773 |
|
| 5774 |
% N.B. { and } should NOT get delcodes; otherwise parameter grouping fails! |
| 5775 |
|
| 5776 |
\def\mathhexbox#1#2#3{\leavevmode |
| 5777 |
\hbox{$\m@th \mathchar"#1#2#3$}} |
| 5778 |
\def\dag{\mathhexbox279} |
| 5779 |
\def\ddag{\mathhexbox27A} |
| 5780 |
\def\S{\mathhexbox278} |
| 5781 |
\def\P{\mathhexbox27B} |
| 5782 |
\end{verbatim} |
| 5783 |
|
| 5784 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5785 |
\subsection{Type 4: Math Open} |
| 5786 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5787 |
|
| 5788 |
|
| 5789 |
latex.ltx, fontmath.ltx, plain.tex |
| 5790 |
|
| 5791 |
|
| 5792 |
|
| 5793 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5794 |
\chapter{Packages} |
| 5795 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 5796 |
|
| 5797 |
%%%%%%%%%%%%%%%%%% |
| 5798 |
\section{Small Ones} |
| 5799 |
%%%%%%%%%%%%%%%%%% |
| 5800 |
|
| 5801 |
|
| 5802 |
|
| 5803 |
\<configure mathml sistyle\><<< |
| 5804 |
\Configure{thousandsep} |
| 5805 |
{\ifmathml |
| 5806 |
\ifmtext\else \Tg<\a:mathml mspace width="0.25em"/>\fi |
| 5807 |
\fi} |
| 5808 |
>>> |
| 5809 |
|
| 5810 |
%%%%%%%%%%%%%% |
| 5811 |
\subsection{stmaryrd} |
| 5812 |
%%%%%%%%%%%%%% |
| 5813 |
|
| 5814 |
|
| 5815 |
\<configure mathml stmaryrd\><<< |
| 5816 |
|
| 5817 |
\def\:tempa{\HCode{<\a:mathml mo fence="false">\string&\#x27E6;</\a:mathml mo>}} |
| 5818 |
\HLet\llbracket\:tempa |
| 5819 |
\def\:tempa{\HCode{<\a:mathml mo fence="false">\string&\#x27E7;</\a:mathml mo>}} |
| 5820 |
\HLet\rrbracket\:tempa |
| 5821 |
>>> |
| 5822 |
|
| 5823 |
Fix for some commands used with \verb|\left| or \verb|\right|. |
| 5824 |
|
| 5825 |
\<configure mathml stmaryrd\><<< |
| 5826 |
\Configure{mfenced}{\llbracket}{\string&\#x27E6;} |
| 5827 |
\Configure{mfenced}{\rrbracket}{\string&\#x27E7;} |
| 5828 |
>>> |
| 5829 |
|
| 5830 |
|
| 5831 |
%%%%%%%%%%%%% |
| 5832 |
\subsection{subeqnarray} |
| 5833 |
%%%%%%%%%%%%% |
| 5834 |
|
| 5835 |
\<configure mathml subeqnarray\><<< |
| 5836 |
\Configure{subeqnarray} |
| 5837 |
{\HCode{<\a:mathml mtable\Hnewline \mml:class="subeqnarray\ifx |
| 5838 |
\@seqncr\@eqncr\else-star\fi" |
| 5839 |
\a:mathml columnalign="right center left" >}}% |
| 5840 |
{\HCode{</\a:mathml mtable>}} |
| 5841 |
{\HCode{<\a:mathml mtr>}} {\HCode{</\a:mathml mtr>}} |
| 5842 |
{\Tg<\a:mathml mtd\Hnewline \mml:class="subeqnarray-\HCol"> |
| 5843 |
\ifnum \HCol=4 |
| 5844 |
\Tg<\a:mathml mtext |
| 5845 |
\mml:class="subeqnarray">|<start mtext space|>\PauseMathClass |
| 5846 |
\mtexttrue |
| 5847 |
|<config math within mtext|>% |
| 5848 |
\fi} |
| 5849 |
{\ifnum \HCol=4 \mtextfalse |
| 5850 |
\EndPauseMathClass|<end mtext space|>\Tg</\a:mathml mtext>\fi |
| 5851 |
\Tg</\a:mathml mtd>} |
| 5852 |
>>> |
| 5853 |
|
| 5854 |
|
| 5855 |
%%%%%%%%%%%%% |
| 5856 |
\subsubsection{Bm} |
| 5857 |
%%%%%%%%%%%%% |
| 5858 |
|
| 5859 |
|
| 5860 |
\<configure mathml bm\><<< |
| 5861 |
\Configure{bm} |
| 5862 |
{\bgroup\ifmmode \ifmtext \else |
| 5863 |
\Tg<\a:mathml mstyle |
| 5864 |
mathvariant="bold">% |
| 5865 |
\expandafter\expandafter\expandafter\:gobble |
| 5866 |
\fi\fi} |
| 5867 |
{\ifmmode \ifmtext \else \Tg</\a:mathml mstyle>\fi\fi\egroup} |
| 5868 |
>>> |
| 5869 |
|
| 5870 |
|
| 5871 |
The bm commands produces bold printing by overprinting the characters |
| 5872 |
with small shifting. |
| 5873 |
|
| 5874 |
|
| 5875 |
%%%%%%%%%%%%%%%%%% |
| 5876 |
\section{Color} |
| 5877 |
%%%%%%%%%%%%%%%%%% |
| 5878 |
|
| 5879 |
|
| 5880 |
|
| 5881 |
\<configure html-mml color\><<< |
| 5882 |
\Configure{textcolor} |
| 5883 |
{\gHAdvance\textcolorN by 1 |
| 5884 |
\Configure{color}% |
| 5885 |
{\Configure{SetHColor} |
| 5886 |
{\Css{.textcolor\textcolorN{color:\HColor}}}}% |
| 5887 |
\HCode{<\ifmathml\a:mathml mstyle\else span\fi |
| 5888 |
\space id="textcolor\textcolorN">}}% |
| 5889 |
{\HCode{</\ifmathml\a:mathml mstyle\else span\fi>}} |
| 5890 |
>>> |
| 5891 |
|
| 5892 |
|
| 5893 |
\<configure html-mml color\><<< |
| 5894 |
\Configure{textcolor} |
| 5895 |
{\ifmathml% |
| 5896 |
\ifmtext|<end mtext space|>\fi\HCode{<\a:mathml mstyle style="color:\:currentcolor;">}% |
| 5897 |
\else% |
| 5898 |
\HCode{<span style="color:\:currentcolor;">}% |
| 5899 |
\fi% |
| 5900 |
}% |
| 5901 |
{\HCode{</\ifmathml\a:mathml mstyle\else span\fi>}\ifmtext|<start mtext space|>\fi} |
| 5902 |
>>> |
| 5903 |
|
| 5904 |
|
| 5905 |
%%%%%%%%%%%%%%%%% |
| 5906 |
\section{mhchem} |
| 5907 |
%%%%%%%%%%%%%%%% |
| 5908 |
|
| 5909 |
|
| 5910 |
\<configure mathml mhchem\><<< |
| 5911 |
\Configure{mhchemcf}{\bgroup\HCode{<\:mhmathmlorhtml{mrow}{span}\space class="mhchem-cf">}}{\HCode{</\:mhmathmlorhtml{mrow}{span}>}\egroup} |
| 5912 |
\Configure{mhchemce}{\bgroup\HCode{<\:mhmathmlorhtml{mrow}{span}\space class="mhchem-ce">}}{\HCode{</\:mhmathmlorhtml{mrow}{span}>}\egroup} |
| 5913 |
|
| 5914 |
% we configure subscripts and superscripts to have empty bases. it is because if superscript followed subscript, we got wrong |
| 5915 |
% MathML markup, with mismatched tags. For example: \ce{CrO4^2-} |
| 5916 |
\Configure{mhchemsub}{% |
| 5917 |
\:mhmathmlorhtml{% |
| 5918 |
\HCode{<\a:mathml msub><mrow></mrow><\a:mathml mrow>}% |
| 5919 |
}{% |
| 5920 |
\HCode{<sub>}}% |
| 5921 |
}{\:mhmathmlorhtml{\Tg</\a:mathml mrow>\TG</\a:mathml msub>}{\HCode{</sub>}}} |
| 5922 |
\Configure{mhchemsup}{% |
| 5923 |
\:mhmathmlorhtml{ |
| 5924 |
\HCode{<\a:mathml msup><mrow></mrow><\a:mathml mrow>}% |
| 5925 |
}{% |
| 5926 |
\HCode{<sup>}}% |
| 5927 |
}{\:mhmathmlorhtml{\Tg</\a:mathml mrow>\TG</\a:mathml msup\Hnewline>}{\HCode{</sup>}}} |
| 5928 |
|
| 5929 |
|
| 5930 |
\Configure{mhchemsupsub}{\setbox0=\hbox\bgroup$}{$\egroup\setbox1=\hbox\bgroup$}{$\egroup\HCode{<\a:mathml msubsup><\a:mathml mrow></\a:mathml mrow><\a:mathml mrow>}\box1\HCode{</\a:mathml mrow><\a:mathml mrow>}\box0\HCode{</\a:mathml mrow></\a:mathml msubsup>}} |
| 5931 |
\Configure{mhchemisotope}{\setbox0=\hbox\bgroup$}{$\egroup\setbox1=\hbox\bgroup$}{$\egroup\HCode{<\a:mathml msubsup><\a:mathml mrow></\a:mathml mrow><\a:mathml mrow>}\box1\HCode{</\a:mathml mrow><\a:mathml mrow>}\box0\HCode{</\a:mathml mrow></\a:mathml msubsup>}} |
| 5932 |
|
| 5933 |
|
| 5934 |
|
| 5935 |
% mhchemoperator is always used inside \HCode, so we need not to use \HCode in it's configuration |
| 5936 |
\Configure{mhchemoperator}{<\:mhmathmlorhtml{mo \a:mathml stretchy="false" }{span} class="mhchem-operator">}{</\:mhmathmlorhtml{mo}{span}>} |
| 5937 |
|
| 5938 |
\Configure{mhchemarrow}{\HCode {<\:mhmathmlorhtml{mrow}{span} class="mhchem-arrow">\:mhonlyinmathml{\a:mhchemoperator}}\PauseMathClass}{\EndPauseMathClass\HCode{\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}} |
| 5939 |
\Configure{mhchemarrowabove}{\HCode{<\:mhmathmlorhtml{mrow}{span} class="mhchem-above">\:mhonlyinmathml{\a:mhchemoperator}}\PauseMathClass}{\EndPauseMathClass\HCode{\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}} |
| 5940 |
\Configure{mhchemarrowyields}{\ensuremath{\HCode{<\:mhmathmlorhtml{mrow}{span} class="mhchem-arrow-normal">\:mhonlyinmathml{\a:mhchemoperator}&\#x27F6;\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}}} |
| 5941 |
\Configure{mhchemarrowyieldsLeft}{\ensuremath{\HCode{<\:mhmathmlorhtml{mrow}{span} class="mhchem-arrow-normal">\:mhonlyinmathml{\a:mhchemoperator}&\#x27F5;\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}}} |
| 5942 |
\Configure{mhchemarrowyieldsLeftRight}{\ensuremath{\HCode{<\a:mathml munder class="mhchem-arrow-larger"><\a:mathml mrow><\a:mathml mpadded height="0" depth="0.3em"><\a:mathml mo stretchy="false" >&\#x27F5;</\a:mathml mo></\a:mathml mpadded></\a:mathml mrow> |
| 5943 |
<\a:mathml mrow><\a:mathml mpadded depth="0" height="0"><\a:mathml mo stretchy="false">&\#x27F6;</\a:mathml mo></\a:mathml mpadded></\a:mathml mrow></\a:mathml munder>} |
| 5944 |
}} |
| 5945 |
\Configure{mhchemarrowmesomerism}{\HCode{<\:mhmathmlorhtml{mrow}{span} class="mhchem-arrow-normal">\:mhonlyinmathml{\a:mhchemoperator}&\#x2194;\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}} % todo: improve |
| 5946 |
% \Configure{mhchemarrowequilibrium}{\ensuremath{\HCode{<\:mhmathmlorhtml{mrow}{span} class="mhchem-arrow-normal">\:mhonlyinmathml{\a:mhchemoperator}&\#x21cc;\:mhonlyinmathml{\b:mhchemoperator}</\:mhmathmlorhtml{mrow}{span}>}}} % todo: improve |
| 5947 |
\Configure{mhchemarrowequilibrium}{\ensuremath{\HCode{<\a:mathml munder class="mhchem-arrow-larger"><\a:mathml mrow><\a:mathml mpadded height="0" depth="0" voffset="-0.1em" ><\a:mathml mo stretchy="true" >&\#x21c0;</\a:mathml mo></\a:mathml mpadded></\a:mathml mrow> |
| 5948 |
<\a:mathml mpadded height="0" depth="0" ><\a:mathml mo stretchy="false">&\#x21bd;</\a:mathml mo></\a:mathml mpadded></\a:mathml munder>} |
| 5949 |
}} % todo: improve |
| 5950 |
% this configuration is inspired by the MathML code from MathJax. There is a problem with vertical positioning of arrows, so we need to use |
| 5951 |
% the <mpadded> element to fix that. It is still not perfect, moreover, there is a difference in rendering between |
| 5952 |
% vanilla Firefox and MathJax's MathML |
| 5953 |
\Configure{mhchemarrowequilibriumRight} |
| 5954 |
{\ensuremath{\HCode{<\a:mathml munder class="mhchem-arrow-larger"><\a:mathml mrow><\a:mathml mpadded height="0" depth="1" voffset="3px"><\a:mathml mo stretchy="true" >&\#x21c0;</\a:mathml mo></\a:mathml mpadded></\a:mathml mrow> |
| 5955 |
<\a:mathml mpadded height="0" depth="1" voffset="2px"><\a:mathml mspace width="0.167em"></\a:mathml mspace><\a:mathml mo stretchy="false">&\#x21bd;</\a:mathml mo><\a:mathml mspace width="0.167em"></\a:mathml mspace></\a:mathml mpadded></\a:mathml munder>} |
| 5956 |
}} % todo: improve |
| 5957 |
\Configure{mhchemarrowequilibriumLeft} |
| 5958 |
{\ensuremath{\HCode{<\a:mathml munder class="mhchem-arrow-larger"><\a:mathml mrow><\a:mathml mpadded height="0" depth="1" voffset="4px"><\a:mathml mspace width="0.167em"></\a:mathml mspace><\a:mathml mo stretchy="false">&\#x21c0;</\a:mathml mo><\a:mathml mspace width="0.167em"></\a:mathml mspace></\a:mathml mpadded></\a:mathml mrow> |
| 5959 |
<\a:mathml mpadded height="0" depth="1" voffset="2px"><\a:mathml mo stretchy="true" >&\#x21bd;</\a:mathml mo></\a:mathml mpadded></\a:mathml munder>} |
| 5960 |
}} % todo: improve |
| 5961 |
|
| 5962 |
% this is not the right symbol |
| 5963 |
% \Configure{mhchemarrowequilibriumRight}{\a:mhchemoperator\HCode{&\#x2942;}\b:mhchemoperator } % todo: improve |
| 5964 |
% \Configure{mhchemarrowequilibriumLeft}{\a:mhchemoperator\HCode{&\#x2943;}\b:mhchemoperator} % todo: improve |
| 5965 |
\Configure{mhchembondhalf}{\HCode{<span class="mhchem-bond-half-middle">&\#xfe4d;</span>}} |
| 5966 |
\Configure{mhchembondoneandhalf}{\HCode{<span class="mhchem-rlap">&\#x2212;</span><span class="mhchem-bond-half-top">&\#xfe4d;</span>}} |
| 5967 |
\Configure{mhchembondtwoandhalf}{\HCode{<span class="mhchem-rlap">=</span><span class="mhchem-bond-half-top">&\#xfe4d;</span>}} |
| 5968 |
\Configure{mhchembondtwoandhalff}{\HCode{<span class="mhchem-rlap mhchem-bond-top">&\#x2212;</span><span class="mhchem-rlap mhchem-bond-bottom">&\#x2212;</span><span class="mhchem-bond-half-middle">&\#xfe4d;</span>}} |
| 5969 |
|
| 5970 |
|<mhchemarrows|> |
| 5971 |
>>> |
| 5972 |
|
| 5973 |
This is a local redefinition of the text over and under arrow handling code for MathML. We need to do change the sequence of |
| 5974 |
elements that are printed to support the munderover element easily. |
| 5975 |
|
| 5976 |
\<mhchemarrows\><<< |
| 5977 |
\ExplSyntaxOn |
| 5978 |
\cs_set_protected:Npn \__mhchem_arrow_deployfourht:nnnnn #1#2#3#4#5 |
| 5979 |
{ |
| 5980 |
\bgroup |
| 5981 |
\ensuremath{% |
| 5982 |
% we need to test if the text is larger than arrow. if it is, the math operator needs to be stretchy. |
| 5983 |
% otherwise, it must be not stretchy, otherwise the text over arrow will be aligned to the right |
| 5984 |
\setbox0=\hbox{\tl_if_empty:nF {#3#5} |
| 5985 |
{ |
| 5986 |
\str_case:nnF {#2} |
| 5987 |
{ |
| 5988 |
{ } { \ce{ #5 } } |
| 5989 |
{ M } { { #5 } } |
| 5990 |
{ T } { \text{ #5 } } |
| 5991 |
{ C } { \ce{ #5 } } |
| 5992 |
} |
| 5993 |
{ \msg_error:nnn { mhchem } { unexpected-arrow-type } {#2} } |
| 5994 |
}} |
| 5995 |
\setbox1=\hbox{\tl_if_empty:nF {#3#5} |
| 5996 |
{ |
| 5997 |
\str_case:nnF {#2} |
| 5998 |
{ |
| 5999 |
{ } { \ce{ #3 } } |
| 6000 |
{ M } { { #3 } } |
| 6001 |
{ T } { \text{ #3 } } |
| 6002 |
{ C } { \ce{ #3 } } |
| 6003 |
} |
| 6004 |
{ \msg_error:nnn { mhchem } { unexpected-arrow-type } {#2} } |
| 6005 |
}} |
| 6006 |
% now compare dimensions of boxes and change math stretchines |
| 6007 |
\ifdim \wd0>1em |
| 6008 |
\Configure{mhchemoperator}{<\a:mathml mo~\a:mathml stretchy="true"~\a:mathml class="mhchem-operator">}{</\a:mathml mo>} |
| 6009 |
\else |
| 6010 |
\ifdim \wd1>1em |
| 6011 |
\Configure{mhchemoperator}{<\a:mathml mo~\a:mathml stretchy="true"~\a:mathml class="mhchem-operator">}{</\a:mathml mo>} |
| 6012 |
\fi |
| 6013 |
\fi |
| 6014 |
\a:mhchemmathlarrow |
| 6015 |
\str_case:nnF {#1} |
| 6016 |
{ |
| 6017 |
{ yields } {\a:mhchemarrowyields } |
| 6018 |
{ yieldsLeft } {\a:mhchemarrowyieldsLeft } |
| 6019 |
{ yieldsLeftRight } {\a:mhchemarrowyieldsLeftRight } % todo: improve |
| 6020 |
{ esomerism } {\a:mhchemarrowesomerism } % todo: improve |
| 6021 |
{ equilibrium } {\a:mhchemarrowequilibrium } % todo: improve |
| 6022 |
{ equilibriumRight } {\a:mhchemarrowequilibriumRight } % todo: improve |
| 6023 |
{ equilibriumLeft } {\a:mhchemarrowequilibriumLeft } % todo: improve |
| 6024 |
} |
| 6025 |
{ \msg_error:nnn { mhchem } { unexpected-arrow-type } {#1} } |
| 6026 |
\b:mhchemmathlarrow |
| 6027 |
\box0 |
| 6028 |
\c:mhchemmathlarrow |
| 6029 |
\box1 |
| 6030 |
\d:mhchemmathlarrow |
| 6031 |
} |
| 6032 |
\egroup |
| 6033 |
} |
| 6034 |
|
| 6035 |
\HRestore\__mhchem_arrow_deploy:nnnnn |
| 6036 |
\HLet\__mhchem_arrow_deploy:nnnnn\__mhchem_arrow_deployfourht:nnnnn |
| 6037 |
\ExplSyntaxOff |
| 6038 |
|
| 6039 |
\NewConfigure{mhchemmathlarrow}{4} |
| 6040 |
\Configure{mhchemmathlarrow}{\HCode{<\a:mathml munderover><\a:mathml mrow>}}{\HCode{</\a:mathml mrow><\a:mathml mpadded>}}{\HCode{</\a:mathml mpadded><\a:mathml mpadded>}}{\HCode{</\a:mathml mpadded></\a:mathml munderover>}} |
| 6041 |
>>> |
| 6042 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6043 |
\section{siunitx} |
| 6044 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6045 |
|
| 6046 |
\<configure mathml siunitx\><<< |
| 6047 |
% redefinitions of Expl 3 syntax commands |
| 6048 |
\ExplSyntaxOn |
| 6049 |
|<siunitx degree celsius|> |
| 6050 |
\ExplSyntaxOff |
| 6051 |
>>> |
| 6052 |
|
| 6053 |
\<siunitx degree celsius\><<< |
| 6054 |
% this fixes circle in degree celsius not printed as superscript |
| 6055 |
\siunitx_declare_unit:Ne \degreeCelsius { \HCode{<\a:mathml msup><\a:mathml mrow /><\a:mathml mi>&\#x2218;</\a:mathml mi></\a:mathml msup>} C } |
| 6056 |
>>> |
| 6057 |
|
| 6058 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6059 |
\section{esvec} |
| 6060 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6061 |
|
| 6062 |
We need to redefine these commands only for MathML. By default, Esvect produces images, which is OK. |
| 6063 |
|
| 6064 |
\<configure mathml esvect\><<< |
| 6065 |
\def\:tempa#1{% |
| 6066 |
\bgroup\HCode{<\a:mathml mover><\a:mathml mrow>}#1\HCode{</\a:mathml mrow><\a:mathml mo \a:mathml stretchy="true">} |
| 6067 |
\PauseMathClass\fldr\EndPauseMathClass% |
| 6068 |
\HCode{</\a:mathml mo></\a:mathml mover>}\egroup |
| 6069 |
} |
| 6070 |
|
| 6071 |
\HRestore\ESV@vecteur |
| 6072 |
\HLet\ESV@vecteur\:tempa |
| 6073 |
>>> |
| 6074 |
|
| 6075 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6076 |
\chapter{Notes} |
| 6077 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6078 |
|
| 6079 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6080 |
\chapter{To Do} |
| 6081 |
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| 6082 |
|
| 6083 |
\begin{itemize} |
| 6084 |
\item Parametric commands as Superscripts or Subscripts: |
| 6085 |
\verb+$E^\frac{1}{2}$+ (instead of \verb+$E^{\frac{1}{2}}$+). |
| 6086 |
|
| 6087 |
\item |
| 6088 |
Numbering is not right justified: |
| 6089 |
|
| 6090 |
\begin{verbatim} |
| 6091 |
\documentclass{amsart} |
| 6092 |
\begin{document} |
| 6093 |
|
| 6094 |
\begin{eqnarray} |
| 6095 |
A &=& B + C |
| 6096 |
\end{eqnarray} |
| 6097 |
|
| 6098 |
\begin{align} |
| 6099 |
A &= B + C \qquad & N &= G + F |
| 6100 |
\end{align} |
| 6101 |
|
| 6102 |
\begin{alignat}{2} |
| 6103 |
A &= B + C \qquad \qquad & N & = G + F |
| 6104 |
\end{alignat} |
| 6105 |
|
| 6106 |
\begin{gather} |
| 6107 |
A = B + C \tag{my equation} \\ |
| 6108 |
B = \text{variable unknown} \notag \\ |
| 6109 |
Y = \max X + \log 10 |
| 6110 |
\end{gather} |
| 6111 |
|
| 6112 |
\end{document} |
| 6113 |
\end{verbatim} |
| 6114 |
|
| 6115 |
|
| 6116 |
\item |
| 6117 |
\begin{verbatim} |
| 6118 |
\begin{align} |
| 6119 |
e &= a + b \\ |
| 6120 |
\intertext{this should be located on the left browser hand margin} |
| 6121 |
a &= u |
| 6122 |
\end{align} |
| 6123 |
|
| 6124 |
\end{verbatim} |
| 6125 |
|
| 6126 |
\end{itemize} |
| 6127 |
|
| 6128 |
|
| 6129 |
|
| 6130 |
\endinput |