зеркало из https://github.com/mozilla/gecko-dev.git
Bug 569124 - Make the math element support the attributes of mstyle. r=karlt
This commit is contained in:
Родитель
4aee9856b2
Коммит
d5dde90b81
|
@ -165,14 +165,14 @@ nsMathMLElement::IsAttributeMapped(const nsIAtom* aAttribute) const
|
|||
tag == nsGkAtoms::mtext_ || tag == nsGkAtoms::mspace_)
|
||||
return FindAttributeDependence(aAttribute, tokenMap,
|
||||
NS_ARRAY_LENGTH(tokenMap));
|
||||
if (tag == nsGkAtoms::mstyle_)
|
||||
if (tag == nsGkAtoms::mstyle_ ||
|
||||
tag == nsGkAtoms::math)
|
||||
return FindAttributeDependence(aAttribute, mstyleMap,
|
||||
NS_ARRAY_LENGTH(mstyleMap));
|
||||
|
||||
if (tag == nsGkAtoms::maction_ ||
|
||||
tag == nsGkAtoms::maligngroup_ ||
|
||||
tag == nsGkAtoms::malignmark_ ||
|
||||
tag == nsGkAtoms::math ||
|
||||
tag == nsGkAtoms::menclose_ ||
|
||||
tag == nsGkAtoms::merror_ ||
|
||||
tag == nsGkAtoms::mfenced_ ||
|
||||
|
|
|
@ -230,6 +230,7 @@ nsMathMLFrame::GetPresentationDataFrom(nsIFrame* aFrame,
|
|||
if (display->mDisplay == NS_STYLE_DISPLAY_BLOCK) {
|
||||
aPresentationData.flags |= NS_MATHML_DISPLAYSTYLE;
|
||||
}
|
||||
aPresentationData.mstyle = frame;
|
||||
break;
|
||||
}
|
||||
frame = frame->GetParent();
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>math as mstyle</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>
|
||||
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
||||
<mfrac numalign="right">
|
||||
<mn>123</mn>
|
||||
<mn>456789</mn>
|
||||
</mfrac>
|
||||
</math>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<math xmlns="http://www.w3.org/1998/Math/MathML">
|
||||
<mstyle scriptsizemultiplier="1.414">
|
||||
<msup>
|
||||
<mi>x</mi>
|
||||
<mn>2</mn>
|
||||
</msup>
|
||||
</mstyle>
|
||||
</math>
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,29 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>math as mstyle</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>
|
||||
<math xmlns="http://www.w3.org/1998/Math/MathML" numalign="right">
|
||||
<mfrac>
|
||||
<mn>123</mn>
|
||||
<mn>456789</mn>
|
||||
</mfrac>
|
||||
</math>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<math xmlns="http://www.w3.org/1998/Math/MathML" scriptsizemultiplier="1.414">
|
||||
<mstyle>
|
||||
<msup>
|
||||
<mi>x</mi>
|
||||
<mn>2</mn>
|
||||
</msup>
|
||||
</mstyle>
|
||||
</math>
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -54,3 +54,4 @@
|
|||
== scale-stretchy-3.xhtml scale-stretchy-3-ref.xhtml
|
||||
!= scale-stretchy-4.xhtml scale-stretchy-4-ref.xhtml
|
||||
!= scale-stretchy-5.xhtml scale-stretchy-5-ref.xhtml
|
||||
== math-as-mstyle-1.xhtml math-as-mstyle-1-ref.xhtml
|
||||
|
|
Загрузка…
Ссылка в новой задаче