Renderer support
| Package | MathJax | KaTeX | XeTeX |
|---|---|---|---|
base | MathJax: Full | KaTeX: Full | XeTeX: Full |
textmacros | MathJax: Full | KaTeX: Full | XeTeX: Full |
Syntax#
\ttTakes no arguments. Same argspec in base and textmacros. Reading argspecs
Examples#
Package variants#
| Package | Signature | Allowed mode | Notes |
|---|---|---|---|
base | | math | Legacy math-mode declaration for switching subsequent symbols in the current group to monospace/typewriter style. |
textmacros | | text | Legacy declaration that switches following text to monospaced/typewriter styling until the current group ends. |
In TeXForm#
TeXForm parses this entry as declarative syntax; the package determines its argument specification.
Equivalent forms#
\mathtt{#1}approximatePrefix command alternative for math mode
\texttt{...}approximate\textttis a command with arguments, whereas\ttis declarative.{\ttfamily ...}exact
See also#
Test cases#
| Input | Case | MathJax | KaTeX | XeTeX |
|---|---|---|---|---|
{\tt a} | Positive · baseline | Pass | Pass | Pass |
| Input | Case | MathJax | KaTeX | XeTeX |
|---|---|---|---|---|
{\tt a} | Positive · baseline | Pass | Pass | Pass |