1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135
|
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>content position with width/height</title>
<link rel="match" href="width-height-002-ref.html">
<link rel="help" href="https://w3c.github.io/mathml-core/#layout-algorithms">
<link rel="help" href="https://w3c.github.io/mathml-core/#fractions-mfrac">
<meta name="assert" content="Verify the inline-start and block-start edges of the math content box for the mtext, mrow, mpadded, mfrac, msqrt, mroot layout algorithms."/>
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
<style>
body, math {
font: 25px/1 Ahem;
color: black;
}
.test {
margin: .5em;
}
.box {
width: 7em;
height: 3em;
border: 1px solid blue;
}
/* Revert style specified in the UA style sheet that changes box size. */
mfrac { padding: 0; }
</style>
</head>
<body>
<div class="test">
<math>
<mtext class="box">X</mtext>
</math>
<math dir="rtl">
<mtext class="box">X</mtext>
</math>
</div>
<div class="test">
<math>
<mrow class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mrow>
</math>
<math dir="rtl">
<mrow class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mrow>
</math>
</div>
<div class="test">
<math>
<mpadded lspace="1em" voffset="-1em" class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mpadded>
</math>
<math dir="rtl">
<mpadded lspace="1em" voffset="-1em" class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mpadded>
</math>
</div>
<div class="test">
<math>
<mpadded width="9em" height="1em" depth=".5em" class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mpadded>
</math>
<math dir="rtl">
<mpadded width="9em" height="1em" depth=".5em" class="box">
<mtext>X</mtext>
<mtext>X</mtext>
<mtext>X</mtext>
</mpadded>
</math>
</div>
<div class="test">
<math>
<mfrac class="box" linethickness="0">
<mtext>X</mtext>
<mtext>X</mtext>
</mfrac>
</math>
<math dir="rtl">
<mfrac class="box" linethickness="0">
<mtext>X</mtext>
<mtext>X</mtext>
</mfrac>
</math>
</div>
<div class="test">
<math>
<msqrt class="box">
<mtext>X</mtext>
</msqrt>
</math>
<math dir="rtl">
<msqrt class="box">
<mtext>X</mtext>
</msqrt>
</math>
</div>
<div class="test">
<math>
<mroot class="box">
<mtext>X</mtext>
<mtext>X</mtext>
</mroot>
</math>
<math dir="rtl">
<mroot class="box">
<mtext>X</mtext>
<mtext>X</mtext>
</mroot>
</math>
</div>
</body>
</htmL>
|