The MathML <mphantom> element is rendered invisibly, but dimensions (such as height, width, and baseline position) are still kept.

Attributes

class, id, style
Provided for use with stylesheets.
mathbackground
The background color. You can use #rgb, #rrggbb and HTML color names.

Examples

Sample rendering: x+  z

Rendering in your browser: x + y + z

<math>

<mrow>
  <mi> x </mi>
  <mo> + </mo> 
  <mphantom>
    <mi> y </mi>
    <mo> + </mo>
  </mphantom>
  <mi> z </mi>
</mrow>

</math>

Specifications

Specification Status Comment
MathML 3.0
The definition of 'mphantom' in that specification.
Recommendation Current specification
MathML 2.0
The definition of 'mphantom' in that specification.
Recommendation Initial specification

Browser compatibility

FeatureChromeEdgeFirefoxInternet ExplorerOperaSafari
Basic support No ?1 No No6
mathbackground No ?4 No No Yes
FeatureAndroid webviewChrome for AndroidEdge mobileFirefox for AndroidOpera AndroidiOS SafariSamsung Internet
Basic support No No ?4 No No ?
mathbackground No No ?4 No6 ?

See also

Document Tags and Contributors

Contributors to this page: fscholz, fred.wang, Sheppy, teoli, jswisher
Last updated by: fscholz,