HTML5 MathML
HTML5 MathML <mpadded> Tag
The <mpadded> tag adjusts the space around its content without changing the content itself. You can add or remove padding and shift the content using dimension attributes.
Definition and usage
The <mpadded> element modifies the bounding box reported for its child content. The width, height and depth attributes change the reported dimensions, lspace adds leading space, and voffset shifts the content vertically. Values may be absolute (like 5px) or relative using + and - prefixes.
Syntax
<mpadded width="+5px" lspace="3px" voffset="2px">
<!-- content -->
</mpadded>Example
<math>
<mrow>
<mi>a</mi>
<mpadded lspace="6px" width="+6px">
<mo>+</mo>
</mpadded>
<mi>b</mi>
</mrow>
</math>The <mpadded> wrapper adds leading space before the + operator and extends its reported width, spreading the term out horizontally.
ℹ️
The <mpadded> element is part of MathML Core and is supported in modern browsers.
