<mtext>

Baseline 2023
Newly available

Since January 2023, this feature works across the latest devices and browser versions. This feature might not work in older devices or browsers.

<mtext> MathML 元素用于呈现没有符号意义的任意文本,例如注释或注解。

若要显示具有符号意义的文本,请改用 <mi><mn><mo><ms>

属性

该元素接受全局 MathML 属性

示例

html
<math display="block">
  <mtext>勾股定理</mtext>
</math>

<math display="block">
  <mtext>/* 在此注释 */</mtext>
</math>

规范

Specification
MathML Core
# text-mtext

浏览器兼容性

Report problems with this compatibility data on GitHub
desktopmobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
mtext

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support
No support
No support