<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[166065] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/166065">166065</a></dd>
<dt>Author</dt> <dd>fred.wang@free.fr</dd>
<dt>Date</dt> <dd>2014-03-21 09:19:36 -0700 (Fri, 21 Mar 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Bug 130345 - Refine childShouldCreateRenderer for MathML elements
https://bugs.webkit.org/show_bug.cgi?id=130345

Reviewed by Chris Fleizach.

Source/WebCore:

This is a follow-up of bug 124128. We add more restrictions on foreign
content of MathML elements.

Tests: mathml/presentation/annotation-children.html
       mathml/presentation/foreign-element-in-token.html

* mathml/MathMLElement.cpp:
(WebCore::MathMLElement::isPresentationMathML): fix line wrapping
(WebCore::MathMLElement::isPhrasingContent):
- move the function from MathMLSelectElement.cpp
- add the constraint &quot;is descendant of a map element&quot; for area.
(WebCore::MathMLElement::isFlowContent): new function to test flow content.
(WebCore::MathMLElement::childShouldCreateRenderer):
- remove annotation since it is now tested in MathMLTextElement
- refine testing of annotation-xml
- do not create renderer for text content in MathML. Such content is only allowed inside token elements.
* mathml/MathMLElement.h: Declare isPhrasingContent and isFlowContent.
* mathml/MathMLSelectElement.cpp: Add new function to test MathML/SVG/HTML encodings.
(WebCore::MathMLSelectElement::isMathMLEncoding):
(WebCore::MathMLSelectElement::isSVGEncoding):
(WebCore::MathMLSelectElement::isHTMLEncoding):
(WebCore::MathMLSelectElement::getSelectedSemanticsChild): use the new functions.
* mathml/MathMLSelectElement.h: Declare the new public functions.
* mathml/MathMLTextElement.cpp: remove the isPhrasingContent function.
(WebCore::MathMLTextElement::childShouldCreateRenderer): Just in case, use the generic StyledElement::childShouldCreateRenderer.

LayoutTests:

We update the references of some tests after the additional
restrictions on MathML children. We replace the foreign-*.html with a
single foreign-element-in-token.html and write more tests to verify the
accepted and reject content.

* mathml/msub-anonymous-child-render-crash-expected.txt: Update reference now that text is only allowed in some token MathML elements.
* mathml/presentation/annotation-children-expected.html: Added.
* mathml/presentation/annotation-children.html: Added.
* mathml/presentation/foreign-element-in-annotation-xml.html: Added.
* mathml/presentation/foreign-element-in-annotation-xml-expected.txt: Added.
* mathml/presentation/foreign-element-in-token-expected.txt: Added.
* mathml/presentation/foreign-element-in-token.html: Added.
* mathml/presentation/foreign-mi-expected-mismatch.html: Removed.
* mathml/presentation/foreign-mi.html: Removed.
* mathml/presentation/foreign-mn-expected-mismatch.html: Removed.
* mathml/presentation/foreign-mn.html: Removed.
* mathml/presentation/foreign-mtext-expected-mismatch.html: Removed.
* mathml/presentation/foreign-mtext-rejected-expected.html: Removed.
* mathml/presentation/foreign-mtext-rejected.html: Removed.
* mathml/presentation/foreign-mtext.html: Removed.
* mathml/presentation/semantics-2.html: the mtext elements can not be direct child of annotation-xml. wrap them in a math tag.
* mathml/presentation/semantics-3.html: ditto.
* mathml/presentation/semantics-4.html: ditto.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsmathmlmsubanonymouschildrendercrashexpectedtxt">trunk/LayoutTests/mathml/msub-anonymous-child-render-crash-expected.txt</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationsemantics2html">trunk/LayoutTests/mathml/presentation/semantics-2.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationsemantics3html">trunk/LayoutTests/mathml/presentation/semantics-3.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationsemantics4html">trunk/LayoutTests/mathml/presentation/semantics-4.html</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoremathmlMathMLElementcpp">trunk/Source/WebCore/mathml/MathMLElement.cpp</a></li>
<li><a href="#trunkSourceWebCoremathmlMathMLElementh">trunk/Source/WebCore/mathml/MathMLElement.h</a></li>
<li><a href="#trunkSourceWebCoremathmlMathMLSelectElementcpp">trunk/Source/WebCore/mathml/MathMLSelectElement.cpp</a></li>
<li><a href="#trunkSourceWebCoremathmlMathMLSelectElementh">trunk/Source/WebCore/mathml/MathMLSelectElement.h</a></li>
<li><a href="#trunkSourceWebCoremathmlMathMLTextElementcpp">trunk/Source/WebCore/mathml/MathMLTextElement.cpp</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsmathmlpresentationannotationchildrenexpectedhtml">trunk/LayoutTests/mathml/presentation/annotation-children-expected.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationannotationchildrenhtml">trunk/LayoutTests/mathml/presentation/annotation-children.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignelementinannotationxmlexpectedtxt">trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml-expected.txt</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignelementinannotationxmlhtml">trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignelementintokenexpectedtxt">trunk/LayoutTests/mathml/presentation/foreign-element-in-token-expected.txt</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignelementintokenhtml">trunk/LayoutTests/mathml/presentation/foreign-element-in-token.html</a></li>
</ul>

<h3>Removed Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmiexpectedmismatchhtml">trunk/LayoutTests/mathml/presentation/foreign-mi-expected-mismatch.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmihtml">trunk/LayoutTests/mathml/presentation/foreign-mi.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmnexpectedmismatchhtml">trunk/LayoutTests/mathml/presentation/foreign-mn-expected-mismatch.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmnhtml">trunk/LayoutTests/mathml/presentation/foreign-mn.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmtextexpectedmismatchhtml">trunk/LayoutTests/mathml/presentation/foreign-mtext-expected-mismatch.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmtextrejectedexpectedhtml">trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected-expected.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmtextrejectedhtml">trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected.html</a></li>
<li><a href="#trunkLayoutTestsmathmlpresentationforeignmtexthtml">trunk/LayoutTests/mathml/presentation/foreign-mtext.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/ChangeLog        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,3 +1,34 @@
</span><ins>+2014-03-21  Frédéric Wang  &lt;fred.wang@free.fr&gt;
+
+        Bug 130345 - Refine childShouldCreateRenderer for MathML elements
+        https://bugs.webkit.org/show_bug.cgi?id=130345
+
+        Reviewed by Chris Fleizach.
+
+        We update the references of some tests after the additional
+        restrictions on MathML children. We replace the foreign-*.html with a
+        single foreign-element-in-token.html and write more tests to verify the
+        accepted and reject content.
+
+        * mathml/msub-anonymous-child-render-crash-expected.txt: Update reference now that text is only allowed in some token MathML elements.
+        * mathml/presentation/annotation-children-expected.html: Added.
+        * mathml/presentation/annotation-children.html: Added.
+        * mathml/presentation/foreign-element-in-annotation-xml.html: Added.
+        * mathml/presentation/foreign-element-in-annotation-xml-expected.txt: Added.
+        * mathml/presentation/foreign-element-in-token-expected.txt: Added.
+        * mathml/presentation/foreign-element-in-token.html: Added.
+        * mathml/presentation/foreign-mi-expected-mismatch.html: Removed.
+        * mathml/presentation/foreign-mi.html: Removed.
+        * mathml/presentation/foreign-mn-expected-mismatch.html: Removed.
+        * mathml/presentation/foreign-mn.html: Removed.
+        * mathml/presentation/foreign-mtext-expected-mismatch.html: Removed.
+        * mathml/presentation/foreign-mtext-rejected-expected.html: Removed.
+        * mathml/presentation/foreign-mtext-rejected.html: Removed.
+        * mathml/presentation/foreign-mtext.html: Removed.
+        * mathml/presentation/semantics-2.html: the mtext elements can not be direct child of annotation-xml. wrap them in a math tag.
+        * mathml/presentation/semantics-3.html: ditto.
+        * mathml/presentation/semantics-4.html: ditto.
+
</ins><span class="cx"> 2014-03-21  Mark Lam  &lt;mark.lam@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         StackLayoutPhase should find the union'ed calleeVariable before accessing its machineLocal.
</span></span></pre></div>
<a id="trunkLayoutTestsmathmlmsubanonymouschildrendercrashexpectedtxt"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/mathml/msub-anonymous-child-render-crash-expected.txt (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/msub-anonymous-child-render-crash-expected.txt        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/msub-anonymous-child-render-crash-expected.txt        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,13 +1,9 @@
</span><span class="cx"> This test passes if it does not crash.
</span><span class="cx"> 
</span><span class="cx"> X
</span><del>-3
</del><span class="cx"> Y
</span><del>-3
</del><span class="cx"> X
</span><del>-3
</del><span class="cx"> 2
</span><span class="cx"> Y
</span><del>-3
</del><span class="cx"> 2
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationannotationchildrenexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/annotation-children-expected.html (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/annotation-children-expected.html                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/annotation-children-expected.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,12 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+  &lt;head&gt;
+    &lt;title&gt;annotation children&lt;/title&gt;
+    &lt;meta charset=&quot;utf-8&quot;/&gt;
+  &lt;/head&gt;
+  &lt;body&gt;
+
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation&gt;PASS&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+
+  &lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/annotation-children-expected.html
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svnmimetype"></a>
<div class="addfile"><h4>Added: svn:mime-type</h4></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationannotationchildrenhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/annotation-children.html (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/annotation-children.html                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/annotation-children.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,14 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+  &lt;head&gt;
+    &lt;title&gt;annotation children&lt;/title&gt;
+    &lt;meta charset=&quot;utf-8&quot;/&gt;
+  &lt;/head&gt;
+  &lt;body&gt;
+
+    &lt;!-- This verifies that the annotation element can only contain text content --&gt;
+
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation&gt;PA&lt;mtext&gt;ERROR&lt;/mtext&gt;SS&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+
+  &lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/annotation-children.html
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svnmimetype"></a>
<div class="addfile"><h4>Added: svn:mime-type</h4></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationforeignelementinannotationxmlexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml-expected.txt (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml-expected.txt                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml-expected.txt        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,43 @@
</span><ins>+x
+y
+
+x
+y
+
+x
+y
+
+span
+
+svg
+
+mathml
+
+div
+
+h1
+
+
+h2
+
+
+h3
+
+
+h4
+
+
+h5
+
+
+h6
+
+
+blockquote
+
+
+svg
+
+mathml
+
+
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml-expected.txt
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationforeignelementinannotationxmlhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml.html (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml.html                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,38 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+  &lt;head&gt;
+    &lt;title&gt;Foreign content in semantics&lt;/title&gt;
+    &lt;script type=&quot;text/javascript&quot;&gt;
+      if (window.testRunner)
+        testRunner.dumpAsText();
+    &lt;/script&gt;
+  &lt;/head&gt;
+  &lt;body&gt;
+  
+    &lt;!-- Text is generally not accepted inside MathML elements. --&gt;
+    &lt;p&gt;&lt;math&gt;ERROR&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;mfrac&gt;&lt;mi&gt;x&lt;/mi&gt;ERROR&lt;mi&gt;y&lt;/mi&gt;&lt;/mfrac&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;munder&gt;&lt;mi&gt;x&lt;/mi&gt;ERROR&lt;mi&gt;y&lt;/mi&gt;&lt;/munder&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;msup&gt;&lt;mi&gt;x&lt;/mi&gt;ERROR&lt;mi&gt;y&lt;/mi&gt;&lt;/msup&gt;&lt;/math&gt;&lt;/p&gt;
+
+    &lt;!-- annotation-xml with HTML encoding accepts flow content. --&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;span&gt;span&lt;/span&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;svg&gt;&lt;text&gt;svg&lt;/text&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;math&gt;&lt;mtext&gt;mathml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;div&gt;div&lt;/div&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h1&gt;h1&lt;/h1&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h2&gt;h2&lt;/h2&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h3&gt;h3&lt;/h3&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h4&gt;h4&lt;/h4&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h5&gt;h5&lt;/h5&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;h6&gt;h6&lt;/h6&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;blockquote&gt;blockquote&lt;/blockquote&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+
+    &lt;!-- annotation-xml with SVG/MathML encoding only accepts the specified type. --&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;image/svg+xml&quot;&gt;&lt;math&gt;&lt;mtext&gt;ERROR&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;image/svg+xml&quot;&gt;&lt;svg&gt;&lt;text&gt;svg&lt;/text&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math&gt;&lt;mtext&gt;mathml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;svg&gt;&lt;text&gt;ERROR&lt;/text&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+
+  &lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/foreign-element-in-annotation-xml.html
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svnmimetype"></a>
<div class="addfile"><h4>Added: svn:mime-type</h4></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationforeignelementintokenexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/foreign-element-in-token-expected.txt (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-element-in-token-expected.txt                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/foreign-element-in-token-expected.txt        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,344 @@
</span><ins>+Foreign phrasing content should create renderers:
+
+a: 
+mi
+
+abbr: 
+mi
+
+b: 
+mi
+
+bdi: 
+mi
+
+bdo: 
+mi
+
+button: 
+mi
+
+cite: 
+mi
+
+code: 
+mi
+
+datalist: 
+mi
+
+del: 
+mi
+
+dfn: 
+mi
+
+em: 
+mi
+
+embed: 
+mi
+
+i: 
+mi
+
+img: 
+mi
+
+input: 
+mi
+
+ins: 
+mi
+
+kbd: 
+mi
+
+keygen: 
+mi
+
+label: 
+mi
+
+mark: 
+mi
+
+math: 
+mi
+
+object: 
+mi
+
+output: 
+mi
+
+q: 
+mi
+
+ruby: 
+mi
+
+s: 
+mi
+
+samp: 
+mi
+
+small: 
+mi
+
+span: 
+mi
+
+strong: 
+mi
+
+sub: 
+mi
+
+sup: 
+mi
+
+svg: 
+mi
+
+u: 
+mi
+
+var: 
+mi
+
+a: 
+mn
+
+abbr: 
+mn
+
+b: 
+mn
+
+bdi: 
+mn
+
+bdo: 
+mn
+
+button: 
+mn
+
+cite: 
+mn
+
+code: 
+mn
+
+datalist: 
+mn
+
+del: 
+mn
+
+dfn: 
+mn
+
+em: 
+mn
+
+embed: 
+mn
+
+i: 
+mn
+
+img: 
+mn
+
+input: 
+mn
+
+ins: 
+mn
+
+kbd: 
+mn
+
+keygen: 
+mn
+
+label: 
+mn
+
+mark: 
+mn
+
+math: 
+mn
+
+object: 
+mn
+
+output: 
+mn
+
+q: 
+mn
+
+ruby: 
+mn
+
+s: 
+mn
+
+samp: 
+mn
+
+small: 
+mn
+
+span: 
+mn
+
+strong: 
+mn
+
+sub: 
+mn
+
+sup: 
+mn
+
+svg: 
+mn
+
+u: 
+mn
+
+var: 
+mn
+
+a: 
+mtext
+
+abbr: 
+mtext
+
+b: 
+mtext
+
+bdi: 
+mtext
+
+bdo: 
+mtext
+
+button: 
+mtext
+
+cite: 
+mtext
+
+code: 
+mtext
+
+datalist: 
+mtext
+
+del: 
+mtext
+
+dfn: 
+mtext
+
+em: 
+mtext
+
+embed: 
+mtext
+
+i: 
+mtext
+
+img: 
+mtext
+
+input: 
+mtext
+
+ins: 
+mtext
+
+kbd: 
+mtext
+
+keygen: 
+mtext
+
+label: 
+mtext
+
+mark: 
+mtext
+
+math: 
+mtext
+
+object: 
+mtext
+
+output: 
+mtext
+
+q: 
+mtext
+
+ruby: 
+mtext
+
+s: 
+mtext
+
+samp: 
+mtext
+
+small: 
+mtext
+
+span: 
+mtext
+
+strong: 
+mtext
+
+sub: 
+mtext
+
+sup: 
+mtext
+
+svg: 
+mtext
+
+u: 
+mtext
+
+var: 
+mtext
+
+Foreign non-phrasing content should not create renderers:
+
+p: 
+
+div: 
+
+h1: 
+
+h2: 
+
+h3: 
+
+h4: 
+
+h6: 
+
+blockquote: 
+
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/foreign-element-in-token-expected.txt
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationforeignelementintokenhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/mathml/presentation/foreign-element-in-token.html (0 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-element-in-token.html                                (rev 0)
+++ trunk/LayoutTests/mathml/presentation/foreign-element-in-token.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -0,0 +1,141 @@
</span><ins>+&lt;!doctype html&gt;
+&lt;html&gt;
+  &lt;head&gt;
+    &lt;title&gt;Foreign content&lt;/title&gt;
+    &lt;script type=&quot;text/javascript&quot;&gt;
+      if (window.testRunner)
+        testRunner.dumpAsText();
+    &lt;/script&gt;
+  &lt;/head&gt;
+  &lt;body&gt;
+  
+    &lt;p&gt;Foreign phrasing content should create renderers:&lt;/p&gt;
+
+    &lt;!-- The following elements are not covered by this test: wbr, audio, data,
+         time, canvas, iframe, map, video, textarea, meter, noscript, progress,
+         script, select, template, br, area. --&gt;
+
+    &lt;p&gt;a: &lt;math&gt;&lt;mi&gt;&lt;a&gt;mi&lt;/a&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;abbr: &lt;math&gt;&lt;mi&gt;&lt;abbr&gt;mi&lt;/abbr&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;b: &lt;math&gt;&lt;mi&gt;&lt;b&gt;mi&lt;/b&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdi: &lt;math&gt;&lt;mi&gt;&lt;bdi&gt;mi&lt;/bdi&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdo: &lt;math&gt;&lt;mi&gt;&lt;bdo&gt;mi&lt;/bdo&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;button: &lt;math&gt;&lt;mi&gt;&lt;button&gt;mi&lt;/button&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;cite: &lt;math&gt;&lt;mi&gt;&lt;cite&gt;mi&lt;/cite&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;code: &lt;math&gt;&lt;mi&gt;&lt;code&gt;mi&lt;/code&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;datalist: &lt;math&gt;&lt;mi&gt;&lt;datalist&gt;mi&lt;/datalist&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;del: &lt;math&gt;&lt;mi&gt;&lt;del&gt;mi&lt;/del&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;dfn: &lt;math&gt;&lt;mi&gt;&lt;dfn&gt;mi&lt;/dfn&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;em: &lt;math&gt;&lt;mi&gt;&lt;em&gt;mi&lt;/em&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;embed: &lt;math&gt;&lt;mi&gt;&lt;embed&gt;mi&lt;/embed&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;i: &lt;math&gt;&lt;mi&gt;&lt;i&gt;mi&lt;/i&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;img: &lt;math&gt;&lt;mi&gt;&lt;img&gt;mi&lt;/img&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;input: &lt;math&gt;&lt;mi&gt;&lt;input&gt;mi&lt;/input&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ins: &lt;math&gt;&lt;mi&gt;&lt;ins&gt;mi&lt;/ins&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;kbd: &lt;math&gt;&lt;mi&gt;&lt;kbd&gt;mi&lt;/kbd&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;keygen: &lt;math&gt;&lt;mi&gt;&lt;keygen&gt;mi&lt;/keygen&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;label: &lt;math&gt;&lt;mi&gt;&lt;label&gt;mi&lt;/label&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;mark: &lt;math&gt;&lt;mi&gt;&lt;mark&gt;mi&lt;/mark&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;math: &lt;math&gt;&lt;mi&gt;&lt;math&gt;&lt;mtext&gt;mi&lt;/mtext&gt;&lt;/math&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;object: &lt;math&gt;&lt;mi&gt;&lt;object&gt;mi&lt;/object&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;output: &lt;math&gt;&lt;mi&gt;&lt;output&gt;mi&lt;/output&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;q: &lt;math&gt;&lt;mi&gt;&lt;q&gt;mi&lt;/q&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ruby: &lt;math&gt;&lt;mi&gt;&lt;ruby&gt;mi&lt;/ruby&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;s: &lt;math&gt;&lt;mi&gt;&lt;s&gt;mi&lt;/s&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;samp: &lt;math&gt;&lt;mi&gt;&lt;samp&gt;mi&lt;/samp&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;small: &lt;math&gt;&lt;mi&gt;&lt;small&gt;mi&lt;/small&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;span: &lt;math&gt;&lt;mi&gt;&lt;span&gt;mi&lt;/span&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;strong: &lt;math&gt;&lt;mi&gt;&lt;strong&gt;mi&lt;/strong&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sub: &lt;math&gt;&lt;mi&gt;&lt;sub&gt;mi&lt;/sub&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sup: &lt;math&gt;&lt;mi&gt;&lt;sup&gt;mi&lt;/sup&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;svg: &lt;math&gt;&lt;mi&gt;&lt;svg&gt;&lt;text&gt;mi&lt;/text&gt;&lt;/svg&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;u: &lt;math&gt;&lt;mi&gt;&lt;u&gt;mi&lt;/u&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;var: &lt;math&gt;&lt;mi&gt;&lt;var&gt;mi&lt;/var&gt;&lt;/mi&gt;&lt;/math&gt;&lt;/p&gt;
+
+    &lt;p&gt;a: &lt;math&gt;&lt;mn&gt;&lt;a&gt;mn&lt;/a&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;abbr: &lt;math&gt;&lt;mn&gt;&lt;abbr&gt;mn&lt;/abbr&gt;&lt;/mn&gt;&lt;/mth&gt;&lt;/p&gt;
+    &lt;p&gt;b: &lt;math&gt;&lt;mn&gt;&lt;b&gt;mn&lt;/b&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdi: &lt;math&gt;&lt;mn&gt;&lt;bdi&gt;mn&lt;/bdi&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdo: &lt;math&gt;&lt;mn&gt;&lt;bdo&gt;mn&lt;/bdo&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;button: &lt;math&gt;&lt;mn&gt;&lt;button&gt;mn&lt;/button&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;cite: &lt;math&gt;&lt;mn&gt;&lt;cite&gt;mn&lt;/cite&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;code: &lt;math&gt;&lt;mn&gt;&lt;code&gt;mn&lt;/code&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;datalist: &lt;math&gt;&lt;mn&gt;&lt;datalist&gt;mn&lt;/datalist&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;del: &lt;math&gt;&lt;mn&gt;&lt;del&gt;mn&lt;/del&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;dfn: &lt;math&gt;&lt;mn&gt;&lt;dfn&gt;mn&lt;/dfn&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;em: &lt;math&gt;&lt;mn&gt;&lt;em&gt;mn&lt;/em&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;embed: &lt;math&gt;&lt;mn&gt;&lt;embed&gt;mn&lt;/embed&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;i: &lt;math&gt;&lt;mn&gt;&lt;i&gt;mn&lt;/i&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;img: &lt;math&gt;&lt;mn&gt;&lt;img&gt;mn&lt;/img&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;input: &lt;math&gt;&lt;mn&gt;&lt;input&gt;mn&lt;/input&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ins: &lt;math&gt;&lt;mn&gt;&lt;ins&gt;mn&lt;/ins&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;kbd: &lt;math&gt;&lt;mn&gt;&lt;kbd&gt;mn&lt;/kbd&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;keygen: &lt;math&gt;&lt;mn&gt;&lt;keygen&gt;mn&lt;/keygen&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;label: &lt;math&gt;&lt;mn&gt;&lt;label&gt;mn&lt;/label&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;mark: &lt;math&gt;&lt;mn&gt;&lt;mark&gt;mn&lt;/mark&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;math: &lt;math&gt;&lt;mn&gt;&lt;math&gt;&lt;mtext&gt;mn&lt;/mtext&gt;&lt;/math&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;object: &lt;math&gt;&lt;mn&gt;&lt;object&gt;mn&lt;/object&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;output: &lt;math&gt;&lt;mn&gt;&lt;output&gt;mn&lt;/output&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;q: &lt;math&gt;&lt;mn&gt;&lt;q&gt;mn&lt;/q&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ruby: &lt;math&gt;&lt;mn&gt;&lt;ruby&gt;mn&lt;/ruby&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;s: &lt;math&gt;&lt;mn&gt;&lt;s&gt;mn&lt;/s&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;samp: &lt;math&gt;&lt;mn&gt;&lt;samp&gt;mn&lt;/samp&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;small: &lt;math&gt;&lt;mn&gt;&lt;small&gt;mn&lt;/small&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;span: &lt;math&gt;&lt;mn&gt;&lt;span&gt;mn&lt;/span&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;strong: &lt;math&gt;&lt;mn&gt;&lt;strong&gt;mn&lt;/strong&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sub: &lt;math&gt;&lt;mn&gt;&lt;sub&gt;mn&lt;/sub&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sup: &lt;math&gt;&lt;mn&gt;&lt;sup&gt;mn&lt;/sup&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;svg: &lt;math&gt;&lt;mn&gt;&lt;svg&gt;&lt;text&gt;mn&lt;/text&gt;&lt;/svg&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;u: &lt;math&gt;&lt;mn&gt;&lt;u&gt;mn&lt;/u&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;var: &lt;math&gt;&lt;mn&gt;&lt;var&gt;mn&lt;/var&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+
+    &lt;p&gt;a: &lt;math&gt;&lt;mtext&gt;&lt;a&gt;mtext&lt;/a&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;abbr: &lt;math&gt;&lt;mtext&gt;&lt;abbr&gt;mtext&lt;/abbr&gt;&lt;/mtext&gt;&lt;/mth&gt;&lt;/p&gt;
+    &lt;p&gt;b: &lt;math&gt;&lt;mtext&gt;&lt;b&gt;mtext&lt;/b&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdi: &lt;math&gt;&lt;mtext&gt;&lt;bdi&gt;mtext&lt;/bdi&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;bdo: &lt;math&gt;&lt;mtext&gt;&lt;bdo&gt;mtext&lt;/bdo&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;button: &lt;math&gt;&lt;mtext&gt;&lt;button&gt;mtext&lt;/button&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;cite: &lt;math&gt;&lt;mtext&gt;&lt;cite&gt;mtext&lt;/cite&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;code: &lt;math&gt;&lt;mtext&gt;&lt;code&gt;mtext&lt;/code&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;datalist: &lt;math&gt;&lt;mtext&gt;&lt;datalist&gt;mtext&lt;/datalist&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;del: &lt;math&gt;&lt;mtext&gt;&lt;del&gt;mtext&lt;/del&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;dfn: &lt;math&gt;&lt;mtext&gt;&lt;dfn&gt;mtext&lt;/dfn&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;em: &lt;math&gt;&lt;mtext&gt;&lt;em&gt;mtext&lt;/em&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;embed: &lt;math&gt;&lt;mtext&gt;&lt;embed&gt;mtext&lt;/embed&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;i: &lt;math&gt;&lt;mtext&gt;&lt;i&gt;mtext&lt;/i&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;img: &lt;math&gt;&lt;mtext&gt;&lt;img&gt;mtext&lt;/img&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;input: &lt;math&gt;&lt;mtext&gt;&lt;input&gt;mtext&lt;/input&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ins: &lt;math&gt;&lt;mtext&gt;&lt;ins&gt;mtext&lt;/ins&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;kbd: &lt;math&gt;&lt;mtext&gt;&lt;kbd&gt;mtext&lt;/kbd&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;keygen: &lt;math&gt;&lt;mtext&gt;&lt;keygen&gt;mtext&lt;/keygen&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;label: &lt;math&gt;&lt;mtext&gt;&lt;label&gt;mtext&lt;/label&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;mark: &lt;math&gt;&lt;mtext&gt;&lt;mark&gt;mtext&lt;/mark&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;math: &lt;math&gt;&lt;mtext&gt;&lt;math&gt;&lt;mtext&gt;mtext&lt;/mtext&gt;&lt;/math&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;object: &lt;math&gt;&lt;mtext&gt;&lt;object&gt;mtext&lt;/object&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;output: &lt;math&gt;&lt;mtext&gt;&lt;output&gt;mtext&lt;/output&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;q: &lt;math&gt;&lt;mtext&gt;&lt;q&gt;mtext&lt;/q&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;ruby: &lt;math&gt;&lt;mtext&gt;&lt;ruby&gt;mtext&lt;/ruby&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;s: &lt;math&gt;&lt;mtext&gt;&lt;s&gt;mtext&lt;/s&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;samp: &lt;math&gt;&lt;mtext&gt;&lt;samp&gt;mtext&lt;/samp&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;small: &lt;math&gt;&lt;mtext&gt;&lt;small&gt;mtext&lt;/small&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;span: &lt;math&gt;&lt;mtext&gt;&lt;span&gt;mtext&lt;/span&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;strong: &lt;math&gt;&lt;mtext&gt;&lt;strong&gt;mtext&lt;/strong&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sub: &lt;math&gt;&lt;mtext&gt;&lt;sub&gt;mtext&lt;/sub&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;sup: &lt;math&gt;&lt;mtext&gt;&lt;sup&gt;mtext&lt;/sup&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;svg: &lt;math&gt;&lt;mtext&gt;&lt;svg&gt;&lt;text&gt;mtext&lt;/text&gt;&lt;/svg&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;u: &lt;math&gt;&lt;mtext&gt;&lt;u&gt;mtext&lt;/u&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;var: &lt;math&gt;&lt;mtext&gt;&lt;var&gt;mtext&lt;/var&gt;&lt;/mtext&gt;&lt;/math&gt;&lt;/p&gt;
+
+    &lt;p&gt;Foreign non-phrasing content should not create renderers:&lt;/p&gt;
+
+    &lt;p&gt;p: &lt;math&gt;&lt;mi&gt;&lt;p&gt;mi&lt;/p&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;p&gt;mi&lt;/p&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;p&gt;mn&lt;/p&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;div: &lt;math&gt;&lt;mi&gt;&lt;div&gt;mi&lt;/div&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;div&gt;mi&lt;/div&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;div&gt;mn&lt;/div&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;h1: &lt;math&gt;&lt;mi&gt;&lt;h1&gt;mi&lt;/h1&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;h1&gt;mi&lt;/h1&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;h1&gt;mn&lt;/h1&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;h2: &lt;math&gt;&lt;mi&gt;&lt;h2&gt;mi&lt;/h2&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;h2&gt;mi&lt;/h2&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;h2&gt;mn&lt;/h2&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;h3: &lt;math&gt;&lt;mi&gt;&lt;h3&gt;mi&lt;/h3&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;h3&gt;mi&lt;/h3&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;h3&gt;mn&lt;/h3&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;h4: &lt;math&gt;&lt;mi&gt;&lt;h4&gt;mi&lt;/h4&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;h4&gt;mi&lt;/h4&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;h4&gt;mn&lt;/h4&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;h6: &lt;math&gt;&lt;mi&gt;&lt;h6&gt;mi&lt;/h6&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;h6&gt;mi&lt;/h6&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;h6&gt;mn&lt;/h6&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+    &lt;p&gt;blockquote: &lt;math&gt;&lt;mi&gt;&lt;blockquote&gt;mi&lt;/blockquote&gt;&lt;/mi&gt;&lt;mtext&gt;&lt;blockquote&gt;mi&lt;/blockquote&gt;&lt;/mtext&gt;&lt;mn&gt;&lt;blockquote&gt;mn&lt;/blockquote&gt;&lt;/mn&gt;&lt;/math&gt;&lt;/p&gt;
+
+  &lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">Property changes on: trunk/LayoutTests/mathml/presentation/foreign-element-in-token.html
</span><span class="cx">___________________________________________________________________
</span></span></pre></div>
<a id="svnmimetype"></a>
<div class="addfile"><h4>Added: svn:mime-type</h4></div>
<a id="svneolstyle"></a>
<div class="addfile"><h4>Added: svn:eol-style</h4></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmiexpectedmismatchhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mi-expected-mismatch.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mi-expected-mismatch.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mi-expected-mismatch.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,11 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mi&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;math&gt;&lt;mi&gt;&lt;/mi&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmihtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mi.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mi.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mi.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,13 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mi&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;!-- The HTML-in-MathML span should be visible. --&gt;
-
-    &lt;math&gt;&lt;mi&gt;&lt;span&gt;HTML-in-MathML&lt;/span&gt;&lt;/mi&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmnexpectedmismatchhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mn-expected-mismatch.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mn-expected-mismatch.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mn-expected-mismatch.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,11 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mn&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;math&gt;&lt;mn&gt;&lt;/mn&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmnhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mn.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mn.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mn.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,13 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mn&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;!-- The HTML-in-MathML span should be visible. --&gt;
-
-    &lt;math&gt;&lt;mn&gt;&lt;span&gt;HTML-in-MathML&lt;/span&gt;&lt;/mn&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmtextexpectedmismatchhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mtext-expected-mismatch.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mtext-expected-mismatch.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mtext-expected-mismatch.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,11 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mtext&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;math&gt;&lt;mtext&gt;&lt;/mtext&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmtextrejectedexpectedhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected-expected.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected-expected.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected-expected.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,15 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mtext&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmtextrejectedhtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mtext-rejected.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,17 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mtext&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;!-- These HTML-in-MathML elements are not phrasing content and should be rejected. --&gt;
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;p&gt;HTML-in-MathML&lt;/p&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;div&gt;HTML-in-MathML&lt;/div&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-    _&lt;math&gt;&lt;mtext&gt;&lt;blockquote&gt;HTML-in-MathML&lt;/blockquote&gt;&lt;/mtext&gt;&lt;/math&gt;_
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationforeignmtexthtml"></a>
<div class="delfile"><h4>Deleted: trunk/LayoutTests/mathml/presentation/foreign-mtext.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/foreign-mtext.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/foreign-mtext.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,13 +0,0 @@
</span><del>-&lt;!doctype html&gt;
-&lt;html&gt;
-  &lt;head&gt;
-    &lt;title&gt;Foreign content in mtext&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;!-- The HTML-in-MathML span should be visible. --&gt;
-
-    &lt;math&gt;&lt;mtext&gt;&lt;span&gt;HTML-in-MathML&lt;/span&gt;&lt;/mtext&gt;&lt;/math&gt;
-
-  &lt;/body&gt;
-&lt;/html&gt;
</del></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationsemantics2html"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/mathml/presentation/semantics-2.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/semantics-2.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/semantics-2.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -2,6 +2,13 @@
</span><span class="cx"> &lt;html&gt;
</span><span class="cx"> &lt;head&gt;
</span><span class="cx">   &lt;title&gt;Semantics&lt;/title&gt;
</span><ins>+  &lt;style type=&quot;text/css&quot;&gt;
+    .nospacing {
+      border: 0 !important;
+      padding: 0 !important;
+      margin: 0 !important;
+    }
+  &lt;/style&gt;
</ins><span class="cx"> &lt;/head&gt;
</span><span class="cx"> 
</span><span class="cx"> &lt;body&gt;
</span><span class="lines">@@ -12,11 +19,11 @@
</span><span class="cx"> 
</span><span class="cx">   &lt;!-- Presentation MathML: the child is displayed --&gt;
</span><span class="cx">   &lt;p&gt;presentation MathML ; annotation: &lt;math&gt;&lt;semantics&gt;&lt;mtext&gt;presentation MathML&lt;/mtext&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</span><del>-  &lt;p&gt;presentation MathML ; annotation-xml: &lt;math&gt;&lt;semantics&gt;&lt;mtext&gt;presentation MathML&lt;/mtext&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</del><ins>+  &lt;p&gt;presentation MathML ; annotation-xml: &lt;math&gt;&lt;semantics&gt;&lt;mtext&gt;presentation MathML&lt;/mtext&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</ins><span class="cx"> 
</span><span class="cx">   &lt;!-- Content MathML: the annotation is displayed --&gt;
</span><span class="cx">   &lt;p&gt;content MathML ; annotation: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;content MathML&lt;/csymbol&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</span><del>-  &lt;p&gt;content MathML ; annotation-xml: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</del><ins>+  &lt;p&gt;content MathML ; annotation-xml: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</ins><span class="cx"> 
</span><span class="cx"> &lt;/body&gt;
</span><span class="cx"> &lt;/html&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationsemantics3html"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/mathml/presentation/semantics-3.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/semantics-3.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/semantics-3.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -2,6 +2,13 @@
</span><span class="cx"> &lt;html&gt;
</span><span class="cx"> &lt;head&gt;
</span><span class="cx">   &lt;title&gt;Semantics&lt;/title&gt;
</span><ins>+  &lt;style type=&quot;text/css&quot;&gt;
+    .nospacing {
+      border: 0 !important;
+      padding: 0 !important;
+      margin: 0 !important;
+    }
+  &lt;/style&gt;
</ins><span class="cx"> &lt;/head&gt;
</span><span class="cx"> 
</span><span class="cx"> &lt;body&gt;
</span><span class="lines">@@ -11,16 +18,16 @@
</span><span class="cx">    - An &lt;annotation-xml&gt; element without src attribute and with one of the encoding among &quot;application/mathml-presentation+xml&quot;, &quot;MathML-Presentation&quot;, &quot;image/svg+xml&quot;, &quot;SVG1.1&quot;, &quot;application/xhtml+xml&quot; and &quot;text/html&quot;.
</span><span class="cx">    --&gt;
</span><span class="cx"> 
</span><del>-  &lt;p&gt;annotation 1: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation 2: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\sin x + 5&lt;/annotation&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation 3: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation src=&quot;external-resource&quot;&gt;error&lt;/annotation&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</del><ins>+  &lt;p&gt;annotation 1: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation 2: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\sin x + 5&lt;/annotation&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation 3: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation src=&quot;external-resource&quot;&gt;error&lt;/annotation&gt;&lt;annotation&gt;annotation&lt;/annotation&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</ins><span class="cx"> 
</span><del>-  &lt;p&gt;annotation-xml 1: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;application/mathml-presentation+xml&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 2: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;MathML-Presentation&quot;&gt;&lt;mtext&gt;MathML-Presentation&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 3: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;image/svg+xml&quot;&gt;&lt;svg width=&quot;20px&quot; height=&quot;20px&quot;&gt;&lt;rect width=&quot;20px&quot; height=&quot;20px&quot; fill=&quot;red&quot; stroke=&quot;none&quot;/&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 4: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;SVG1.1&quot;&gt;&lt;svg width=&quot;20px&quot; height=&quot;20px&quot;&gt;&lt;rect width=&quot;20px&quot; height=&quot;20px&quot; fill=&quot;red&quot; stroke=&quot;none&quot;/&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 5: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/xhtml+xml&quot;&gt;&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;&lt;head&gt;&lt;title&gt;application/xhtml+xml&lt;/title&gt;&lt;/head&gt;&lt;body&gt;&lt;p&gt;application/xhtml+xml&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 6: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;html&gt;&lt;head&gt;&lt;title&gt;text/html&lt;/title&gt;&lt;/head&gt;&lt;body&gt;&lt;p&gt;text/html&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
-  &lt;p&gt;annotation-xml 7: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;unknown&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml+xml&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</del><ins>+  &lt;p&gt;annotation-xml 1: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;application/mathml-presentation+xml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 2: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;MathML-Presentation&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;MathML-Presentation&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 3: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;image/svg+xml&quot;&gt;&lt;svg width=&quot;20px&quot; height=&quot;20px&quot;&gt;&lt;rect width=&quot;20px&quot; height=&quot;20px&quot; fill=&quot;red&quot; stroke=&quot;none&quot;/&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 4: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;SVG1.1&quot;&gt;&lt;svg width=&quot;20px&quot; height=&quot;20px&quot;&gt;&lt;rect width=&quot;20px&quot; height=&quot;20px&quot; fill=&quot;red&quot; stroke=&quot;none&quot;/&gt;&lt;/svg&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 5: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;application/xhtml+xml&quot;&gt;&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;&lt;head&gt;&lt;title&gt;application/xhtml+xml&lt;/title&gt;&lt;/head&gt;&lt;body&gt;&lt;p&gt;application/xhtml+xml&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 6: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;text/html&quot;&gt;&lt;html&gt;&lt;head&gt;&lt;title&gt;text/html&lt;/title&gt;&lt;/head&gt;&lt;body&gt;&lt;p&gt;text/html&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
+  &lt;p&gt;annotation-xml 7: &lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml encoding=&quot;unknown&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;error&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation-xml encoding=&quot;application/mathml-presentation+xml&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;annotation-xml&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;error&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</ins><span class="cx"> &lt;/body&gt;
</span><span class="cx"> &lt;/html&gt;
</span></span></pre></div>
<a id="trunkLayoutTestsmathmlpresentationsemantics4html"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/mathml/presentation/semantics-4.html (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/mathml/presentation/semantics-4.html        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/LayoutTests/mathml/presentation/semantics-4.html        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -2,13 +2,20 @@
</span><span class="cx"> &lt;html&gt;
</span><span class="cx"> &lt;head&gt;
</span><span class="cx">   &lt;title&gt;Semantics&lt;/title&gt;
</span><ins>+  &lt;style type=&quot;text/css&quot;&gt;
+    .nospacing {
+      border: 0 !important;
+      padding: 0 !important;
+      margin: 0 !important;
+    }
+  &lt;/style&gt;
</ins><span class="cx"> &lt;/head&gt;
</span><span class="cx"> 
</span><span class="cx"> &lt;body onload=&quot;document.getElementById('a').setAttribute('encoding', 'MathML-Presentation')&quot;&gt;
</span><span class="cx"> 
</span><span class="cx">   &lt;!-- This test verifies that setting the encoding dynamically updates the selected annotation. This should render the same as the static reference. --&gt;
</span><span class="cx"> 
</span><del>-  &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml id=&quot;a&quot;&gt;&lt;mtext&gt;PASS&lt;/mtext&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;FAIL&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</del><ins>+  &lt;p&gt;&lt;math&gt;&lt;semantics&gt;&lt;csymbol&gt;Content MathML&lt;/csymbol&gt;&lt;annotation-xml id=&quot;a&quot;&gt;&lt;math class=&quot;nospacing&quot;&gt;&lt;mtext&gt;PASS&lt;/mtext&gt;&lt;/math&gt;&lt;/annotation-xml&gt;&lt;annotation&gt;FAIL&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/p&gt;
</ins><span class="cx"> 
</span><span class="cx"> &lt;/body&gt;
</span><span class="cx"> &lt;/html&gt;
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/ChangeLog        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -1,3 +1,36 @@
</span><ins>+2014-03-21  Frédéric Wang  &lt;fred.wang@free.fr&gt;
+
+        Bug 130345 - Refine childShouldCreateRenderer for MathML elements
+        https://bugs.webkit.org/show_bug.cgi?id=130345
+
+        Reviewed by Chris Fleizach.
+
+        This is a follow-up of bug 124128. We add more restrictions on foreign
+        content of MathML elements.
+
+        Tests: mathml/presentation/annotation-children.html
+               mathml/presentation/foreign-element-in-token.html
+
+        * mathml/MathMLElement.cpp:
+        (WebCore::MathMLElement::isPresentationMathML): fix line wrapping
+        (WebCore::MathMLElement::isPhrasingContent):
+        - move the function from MathMLSelectElement.cpp
+        - add the constraint &quot;is descendant of a map element&quot; for area.
+        (WebCore::MathMLElement::isFlowContent): new function to test flow content.
+        (WebCore::MathMLElement::childShouldCreateRenderer):
+        - remove annotation since it is now tested in MathMLTextElement
+        - refine testing of annotation-xml
+        - do not create renderer for text content in MathML. Such content is only allowed inside token elements.
+        * mathml/MathMLElement.h: Declare isPhrasingContent and isFlowContent.
+        * mathml/MathMLSelectElement.cpp: Add new function to test MathML/SVG/HTML encodings.
+        (WebCore::MathMLSelectElement::isMathMLEncoding):
+        (WebCore::MathMLSelectElement::isSVGEncoding):
+        (WebCore::MathMLSelectElement::isHTMLEncoding):
+        (WebCore::MathMLSelectElement::getSelectedSemanticsChild): use the new functions.
+        * mathml/MathMLSelectElement.h: Declare the new public functions.
+        * mathml/MathMLTextElement.cpp: remove the isPhrasingContent function.
+        (WebCore::MathMLTextElement::childShouldCreateRenderer): Just in case, use the generic StyledElement::childShouldCreateRenderer.
+
</ins><span class="cx"> 2014-03-21  Darin Adler  &lt;darin@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Stop using deprecatedCharacters in WebCore/platform/win
</span></span></pre></div>
<a id="trunkSourceWebCoremathmlMathMLElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/mathml/MathMLElement.cpp (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/mathml/MathMLElement.cpp        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/mathml/MathMLElement.cpp        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -31,8 +31,15 @@
</span><span class="cx"> 
</span><span class="cx"> #include &quot;MathMLElement.h&quot;
</span><span class="cx"> 
</span><ins>+#include &quot;ElementIterator.h&quot;
+#include &quot;HTMLElement.h&quot;
+#include &quot;HTMLMapElement.h&quot;
+#include &quot;HTMLNames.h&quot;
</ins><span class="cx"> #include &quot;MathMLNames.h&quot;
</span><ins>+#include &quot;MathMLSelectElement.h&quot;
</ins><span class="cx"> #include &quot;RenderTableCell.h&quot;
</span><ins>+#include &quot;SVGElement.h&quot;
+#include &quot;SVGNames.h&quot;
</ins><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx">     
</span><span class="lines">@@ -50,9 +57,142 @@
</span><span class="cx"> 
</span><span class="cx"> bool MathMLElement::isPresentationMathML() const
</span><span class="cx"> {
</span><del>-    return hasTagName(MathMLNames::mtrTag) || hasTagName(MathMLNames::mtdTag) || hasTagName(MathMLNames::maligngroupTag) || hasTagName(MathMLNames::malignmarkTag) || hasTagName(MathMLNames::mencloseTag) || hasTagName(MathMLNames::mglyphTag) || hasTagName(MathMLNames::mlabeledtrTag) || hasTagName(MathMLNames::mlongdivTag) || hasTagName(MathMLNames::mpaddedTag) || hasTagName(MathMLNames::msTag) || hasTagName(MathMLNames::mscarriesTag) || hasTagName(MathMLNames::mscarryTag) || hasTagName(MathMLNames::msgroupTag) || hasTagName(MathMLNames::mslineTag) || hasTagName(MathMLNames::msrowTag) || hasTagName(MathMLNames::mstackTag);
</del><ins>+    return hasTagName(MathMLNames::mtrTag)
+        || hasTagName(MathMLNames::mtdTag)
+        || hasTagName(MathMLNames::maligngroupTag)
+        || hasTagName(MathMLNames::malignmarkTag)
+        || hasTagName(MathMLNames::mencloseTag)
+        || hasTagName(MathMLNames::mglyphTag)
+        || hasTagName(MathMLNames::mlabeledtrTag)
+        || hasTagName(MathMLNames::mlongdivTag)
+        || hasTagName(MathMLNames::mpaddedTag)
+        || hasTagName(MathMLNames::msTag)
+        || hasTagName(MathMLNames::mscarriesTag)
+        || hasTagName(MathMLNames::mscarryTag)
+        || hasTagName(MathMLNames::msgroupTag)
+        || hasTagName(MathMLNames::mslineTag)
+        || hasTagName(MathMLNames::msrowTag)
+        || hasTagName(MathMLNames::mstackTag);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool MathMLElement::isPhrasingContent(const Node&amp; node) const
+{
+    // Phrasing content is described in the HTML 5 specification:
+    // http://www.w3.org/TR/html5/dom.html#phrasing-content.
+
+    if (!node.isElementNode())
+        return node.isTextNode();
+
+    if (node.isMathMLElement()) {
+        auto&amp; mathmlElement = toMathMLElement(node);
+        return mathmlElement.hasTagName(MathMLNames::mathTag);
+    }
+
+    if (node.isSVGElement()) {
+        auto&amp; svgElement = toSVGElement(node);
+        return svgElement.hasTagName(SVGNames::svgTag);
+    }
+
+    if (node.isHTMLElement()) {
+        // FIXME: add the &lt;data&gt; and &lt;time&gt; tags when they are implemented.
+        auto&amp; htmlElement = toHTMLElement(node);
+        return htmlElement.hasTagName(HTMLNames::aTag)
+            || htmlElement.hasTagName(HTMLNames::abbrTag)
+            || (htmlElement.hasTagName(HTMLNames::areaTag) &amp;&amp; ancestorsOfType&lt;HTMLMapElement&gt;(htmlElement).first())
+            || htmlElement.hasTagName(HTMLNames::audioTag)
+            || htmlElement.hasTagName(HTMLNames::bTag)
+            || htmlElement.hasTagName(HTMLNames::bdiTag)
+            || htmlElement.hasTagName(HTMLNames::bdoTag)
+            || htmlElement.hasTagName(HTMLNames::brTag)
+            || htmlElement.hasTagName(HTMLNames::buttonTag)
+            || htmlElement.hasTagName(HTMLNames::canvasTag)
+            || htmlElement.hasTagName(HTMLNames::citeTag)
+            || htmlElement.hasTagName(HTMLNames::codeTag)
+            || htmlElement.hasTagName(HTMLNames::datalistTag)
+            || htmlElement.hasTagName(HTMLNames::delTag)
+            || htmlElement.hasTagName(HTMLNames::dfnTag)
+            || htmlElement.hasTagName(HTMLNames::emTag)
+            || htmlElement.hasTagName(HTMLNames::embedTag)
+            || htmlElement.hasTagName(HTMLNames::iTag)
+            || htmlElement.hasTagName(HTMLNames::iframeTag)
+            || htmlElement.hasTagName(HTMLNames::imgTag)
+            || htmlElement.hasTagName(HTMLNames::inputTag)
+            || htmlElement.hasTagName(HTMLNames::insTag)
+            || htmlElement.hasTagName(HTMLNames::kbdTag)
+            || htmlElement.hasTagName(HTMLNames::keygenTag)
+            || htmlElement.hasTagName(HTMLNames::labelTag)
+            || htmlElement.hasTagName(HTMLNames::mapTag)
+            || htmlElement.hasTagName(HTMLNames::markTag)
+            || htmlElement.hasTagName(HTMLNames::meterTag)
+            || htmlElement.hasTagName(HTMLNames::noscriptTag)
+            || htmlElement.hasTagName(HTMLNames::objectTag)
+            || htmlElement.hasTagName(HTMLNames::outputTag)
+            || htmlElement.hasTagName(HTMLNames::progressTag)
+            || htmlElement.hasTagName(HTMLNames::qTag)
+            || htmlElement.hasTagName(HTMLNames::rubyTag)
+            || htmlElement.hasTagName(HTMLNames::sTag)
+            || htmlElement.hasTagName(HTMLNames::sampTag)
+            || htmlElement.hasTagName(HTMLNames::scriptTag)
+            || htmlElement.hasTagName(HTMLNames::selectTag)
+            || htmlElement.hasTagName(HTMLNames::smallTag)
+            || htmlElement.hasTagName(HTMLNames::spanTag)
+            || htmlElement.hasTagName(HTMLNames::strongTag)
+            || htmlElement.hasTagName(HTMLNames::subTag)
+            || htmlElement.hasTagName(HTMLNames::supTag)
+            || htmlElement.hasTagName(HTMLNames::templateTag)
+            || htmlElement.hasTagName(HTMLNames::textareaTag)
+            || htmlElement.hasTagName(HTMLNames::uTag)
+            || htmlElement.hasTagName(HTMLNames::varTag)
+            || htmlElement.hasTagName(HTMLNames::videoTag)
+            || htmlElement.hasTagName(HTMLNames::wbrTag);
+    }
+
+    return false;
+}
+
+bool MathMLElement::isFlowContent(const Node&amp; node) const
+{
+    // Flow content is described in the HTML 5 specification:
+    // http://www.w3.org/TR/html5/dom.html#flow-content
+
+    if (isPhrasingContent(node))
+        return true;
+
+    if (!node.isHTMLElement())
+        return false;
+
+    auto&amp; htmlElement = toHTMLElement(node);
+    // FIXME add the &lt;dialog&gt; tag when it is implemented.
+    return htmlElement.hasTagName(HTMLNames::addressTag)
+        || htmlElement.hasTagName(HTMLNames::articleTag)
+        || htmlElement.hasTagName(HTMLNames::asideTag)
+        || htmlElement.hasTagName(HTMLNames::blockquoteTag)
+        || htmlElement.hasTagName(HTMLNames::detailsTag)
+        || htmlElement.hasTagName(HTMLNames::divTag)
+        || htmlElement.hasTagName(HTMLNames::dlTag)
+        || htmlElement.hasTagName(HTMLNames::fieldsetTag)
+        || htmlElement.hasTagName(HTMLNames::figureTag)
+        || htmlElement.hasTagName(HTMLNames::footerTag)
+        || htmlElement.hasTagName(HTMLNames::formTag)
+        || htmlElement.hasTagName(HTMLNames::h1Tag)
+        || htmlElement.hasTagName(HTMLNames::h2Tag)
+        || htmlElement.hasTagName(HTMLNames::h3Tag)
+        || htmlElement.hasTagName(HTMLNames::h4Tag)
+        || htmlElement.hasTagName(HTMLNames::h5Tag)
+        || htmlElement.hasTagName(HTMLNames::h6Tag)
+        || htmlElement.hasTagName(HTMLNames::headerTag)
+        || htmlElement.hasTagName(HTMLNames::hrTag)
+        || htmlElement.hasTagName(HTMLNames::mainTag)
+        || htmlElement.hasTagName(HTMLNames::navTag)
+        || htmlElement.hasTagName(HTMLNames::olTag)
+        || htmlElement.hasTagName(HTMLNames::pTag)
+        || htmlElement.hasTagName(HTMLNames::preTag)
+        || htmlElement.hasTagName(HTMLNames::sectionTag)
+        || (htmlElement.hasTagName(HTMLNames::styleTag) &amp;&amp; htmlElement.hasAttribute(&quot;scoped&quot;))
+        || htmlElement.hasTagName(HTMLNames::tableTag)
+        || htmlElement.hasTagName(HTMLNames::ulTag);
+}
+
</ins><span class="cx"> int MathMLElement::colSpan() const
</span><span class="cx"> {
</span><span class="cx">     if (!hasTagName(mtdTag))
</span><span class="lines">@@ -123,13 +263,31 @@
</span><span class="cx"> 
</span><span class="cx"> bool MathMLElement::childShouldCreateRenderer(const Node&amp; child) const
</span><span class="cx"> {
</span><del>-    if (hasTagName(annotationTag))
-        return child.isTextNode();
-    if (hasTagName(annotation_xmlTag))
-        return StyledElement::childShouldCreateRenderer(child);
</del><ins>+    if (hasTagName(annotation_xmlTag)) {
+        const AtomicString&amp; value = fastGetAttribute(MathMLNames::encodingAttr);
</ins><span class="cx"> 
</span><del>-    // Only create renderers for MathML elements or text. MathML prohibits non-MathML markup inside a &lt;math&gt; element.
-    return child.isTextNode() || child.isMathMLElement();
</del><ins>+        // See annotation-xml.model.mathml, annotation-xml.model.svg and annotation-xml.model.xhtml in the HTML5 RelaxNG schema.
+
+        if (child.isMathMLElement() &amp;&amp; (MathMLSelectElement::isMathMLEncoding(value) || MathMLSelectElement::isHTMLEncoding(value))) {
+            auto&amp; mathmlElement = toMathMLElement(child);
+            return mathmlElement.hasTagName(MathMLNames::mathTag);
+        }
+
+        if (child.isSVGElement() &amp;&amp; (MathMLSelectElement::isSVGEncoding(value) || MathMLSelectElement::isHTMLEncoding(value))) {
+            auto&amp; svgElement = toSVGElement(child);
+            return svgElement.hasTagName(SVGNames::svgTag);
+        }
+
+        if (child.isHTMLElement() &amp;&amp; MathMLSelectElement::isHTMLEncoding(value)) {
+            auto&amp; htmlElement = toHTMLElement(child);
+            return htmlElement.hasTagName(HTMLNames::htmlTag) || (isFlowContent(htmlElement) &amp;&amp; StyledElement::childShouldCreateRenderer(child));
+        }
+
+        return false;
+    }
+
+    // In general, only MathML children are allowed. Text nodes are only visible in token MathML elements.
+    return child.isMathMLElement();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void MathMLElement::attributeChanged(const QualifiedName&amp; name, const AtomicString&amp; oldValue, const AtomicString&amp; newValue, AttributeModificationReason reason)
</span></span></pre></div>
<a id="trunkSourceWebCoremathmlMathMLElementh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/mathml/MathMLElement.h (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/mathml/MathMLElement.h        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/mathml/MathMLElement.h        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -66,6 +66,9 @@
</span><span class="cx">     virtual bool isPresentationAttribute(const QualifiedName&amp;) const override;
</span><span class="cx">     virtual void collectStyleForPresentationAttribute(const QualifiedName&amp;, const AtomicString&amp;, MutableStyleProperties&amp;) override;
</span><span class="cx"> 
</span><ins>+    bool isPhrasingContent(const Node&amp;) const;
+    bool isFlowContent(const Node&amp;) const;
+
</ins><span class="cx"> private:
</span><span class="cx">     virtual void updateSelectedChild() { }
</span><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoremathmlMathMLSelectElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/mathml/MathMLSelectElement.cpp (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/mathml/MathMLSelectElement.cpp        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/mathml/MathMLSelectElement.cpp        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -29,8 +29,12 @@
</span><span class="cx"> #if ENABLE(MATHML)
</span><span class="cx"> 
</span><span class="cx"> #include &quot;Event.h&quot;
</span><ins>+#include &quot;HTMLElement.h&quot;
+#include &quot;HTMLNames.h&quot;
</ins><span class="cx"> #include &quot;MathMLNames.h&quot;
</span><span class="cx"> #include &quot;RenderMathMLRow.h&quot;
</span><ins>+#include &quot;SVGElement.h&quot;
+#include &quot;SVGNames.h&quot;
</ins><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><span class="lines">@@ -52,6 +56,29 @@
</span><span class="cx">     return createRenderer&lt;RenderMathMLRow&gt;(*this, std::move(style));
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+//  We recognize the following values for the encoding attribute of the &lt;semantics&gt; element:
+//
+// - &quot;MathML-Presentation&quot;, which is mentioned in the MathML 3 recommendation.
+// - &quot;SVG1.1&quot; which is mentioned in the W3C note.
+//   http://www.w3.org/Math/Documents/Notes/graphics.xml
+// - Other MIME Content-Types for MathML, SVG and HTML.
+//
+// We exclude &quot;application/mathml+xml&quot; which is ambiguous about whether it is Presentation or Content MathML. Authors must use a more explicit encoding value.
+bool MathMLSelectElement::isMathMLEncoding(const AtomicString&amp; value)
+{
+    return value == &quot;application/mathml-presentation+xml&quot; || value == &quot;MathML-Presentation&quot;;
+}
+
+bool MathMLSelectElement::isSVGEncoding(const AtomicString&amp; value)
+{
+    return value == &quot;image/svg+xml&quot; || value == &quot;SVG1.1&quot;;
+}
+
+bool MathMLSelectElement::isHTMLEncoding(const AtomicString&amp; value)
+{
+    return value == &quot;application/xhtml+xml&quot; || value == &quot;text/html&quot;;
+}
+
</ins><span class="cx"> bool MathMLSelectElement::childShouldCreateRenderer(const Node&amp; child) const
</span><span class="cx"> {
</span><span class="cx">     return MathMLElement::childShouldCreateRenderer(child) &amp;&amp; m_selectedChild == &amp;child;
</span><span class="lines">@@ -155,16 +182,9 @@
</span><span class="cx">             // If the &lt;annotation-xml&gt; element has an src attribute then it is a reference to arbitrary binary data and it is not clear whether we can display it. Hence we just ignore the annotation.
</span><span class="cx">             if (child-&gt;hasAttribute(MathMLNames::srcAttr))
</span><span class="cx">                 continue;
</span><del>-            // If the &lt;annotation-xml&gt; element has an encoding attribute describing presentation MathML, SVG or HTML we assume the content can be displayed and we stop here. We recognize the following encoding values:
-            //
-            // - &quot;MathML-Presentation&quot;, which is mentioned in the MathML 3 recommendation.
-            // - &quot;SVG1.1&quot; which is mentioned in the W3C note.
-            //   http://www.w3.org/Math/Documents/Notes/graphics.xml
-            // - Other MIME Content-Types for SVG and HTML.
-            //
-            // We exclude &quot;application/mathml+xml&quot; which is ambiguous about whether it is Presentation or Content MathML. Authors must use a more explicit encoding value.
</del><ins>+            // If the &lt;annotation-xml&gt; element has an encoding attribute describing presentation MathML, SVG or HTML we assume the content can be displayed and we stop here.
</ins><span class="cx">             const AtomicString&amp; value = child-&gt;fastGetAttribute(MathMLNames::encodingAttr);
</span><del>-            if (value == &quot;application/mathml-presentation+xml&quot; || value == &quot;MathML-Presentation&quot; || value == &quot;image/svg+xml&quot; || value == &quot;SVG1.1&quot; || value == &quot;application/xhtml+xml&quot; || value == &quot;text/html&quot;)
</del><ins>+            if (isMathMLEncoding(value) || isSVGEncoding(value) || isHTMLEncoding(value))
</ins><span class="cx">                 return child;
</span><span class="cx">         }
</span><span class="cx">     }
</span></span></pre></div>
<a id="trunkSourceWebCoremathmlMathMLSelectElementh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/mathml/MathMLSelectElement.h (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/mathml/MathMLSelectElement.h        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/mathml/MathMLSelectElement.h        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -34,6 +34,9 @@
</span><span class="cx"> class MathMLSelectElement final : public MathMLInlineContainerElement {
</span><span class="cx"> public:
</span><span class="cx">     static PassRefPtr&lt;MathMLSelectElement&gt; create(const QualifiedName&amp; tagName, Document&amp;);
</span><ins>+    static bool isMathMLEncoding(const AtomicString&amp; value);
+    static bool isSVGEncoding(const AtomicString&amp; value);
+    static bool isHTMLEncoding(const AtomicString&amp; value);
</ins><span class="cx"> 
</span><span class="cx"> private:
</span><span class="cx">     MathMLSelectElement(const QualifiedName&amp; tagName, Document&amp;);
</span></span></pre></div>
<a id="trunkSourceWebCoremathmlMathMLTextElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/mathml/MathMLTextElement.cpp (166064 => 166065)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/mathml/MathMLTextElement.cpp        2014-03-21 16:04:31 UTC (rev 166064)
+++ trunk/Source/WebCore/mathml/MathMLTextElement.cpp        2014-03-21 16:19:36 UTC (rev 166065)
</span><span class="lines">@@ -30,14 +30,10 @@
</span><span class="cx"> 
</span><span class="cx"> #include &quot;MathMLTextElement.h&quot;
</span><span class="cx"> 
</span><del>-#include &quot;HTMLElement.h&quot;
-#include &quot;HTMLNames.h&quot;
</del><span class="cx"> #include &quot;MathMLNames.h&quot;
</span><span class="cx"> #include &quot;RenderMathMLOperator.h&quot;
</span><span class="cx"> #include &quot;RenderMathMLSpace.h&quot;
</span><span class="cx"> #include &quot;RenderMathMLToken.h&quot;
</span><del>-#include &quot;SVGElement.h&quot;
-#include &quot;SVGNames.h&quot;
</del><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx">     
</span><span class="lines">@@ -82,83 +78,6 @@
</span><span class="cx">     return createRenderer&lt;RenderMathMLToken&gt;(*this, std::move(style));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static bool isPhrasingContent(const Node&amp; node)
-{
-    // Phrasing content is described in the HTML 5 specification:
-    // http://www.w3.org/TR/html5/dom.html#phrasing-content.
-
-    if (!node.isElementNode())
-        return node.isTextNode();
-
-    auto&amp; element = toElement(node);
-
-    if (element.isMathMLElement()) {
-        auto&amp; mathmlElement = toMathMLElement(element);
-        return mathmlElement.hasTagName(MathMLNames::mathTag);
-    }
-
-    if (element.isSVGElement()) {
-        auto&amp; svgElement = toSVGElement(element);
-        return svgElement.hasTagName(SVGNames::svgTag);
-    }
-
-    if (element.isHTMLElement()) {
-        // FIXME: add the &lt;data&gt; and &lt;time&gt; tags when they are implemented.
-        auto&amp; htmlElement = toHTMLElement(element);
-        return htmlElement.hasTagName(HTMLNames::aTag)
-            || htmlElement.hasTagName(HTMLNames::abbrTag)
-            || htmlElement.hasTagName(HTMLNames::areaTag)
-            || htmlElement.hasTagName(HTMLNames::audioTag)
-            || htmlElement.hasTagName(HTMLNames::bTag)
-            || htmlElement.hasTagName(HTMLNames::bdiTag)
-            || htmlElement.hasTagName(HTMLNames::bdoTag)
-            || htmlElement.hasTagName(HTMLNames::brTag)
-            || htmlElement.hasTagName(HTMLNames::buttonTag)
-            || htmlElement.hasTagName(HTMLNames::canvasTag)
-            || htmlElement.hasTagName(HTMLNames::citeTag)
-            || htmlElement.hasTagName(HTMLNames::codeTag)
-            || htmlElement.hasTagName(HTMLNames::datalistTag)
-            || htmlElement.hasTagName(HTMLNames::delTag)
-            || htmlElement.hasTagName(HTMLNames::dfnTag)
-            || htmlElement.hasTagName(HTMLNames::emTag)
-            || htmlElement.hasTagName(HTMLNames::embedTag)
-            || htmlElement.hasTagName(HTMLNames::iTag)
-            || htmlElement.hasTagName(HTMLNames::iframeTag)
-            || htmlElement.hasTagName(HTMLNames::imgTag)
-            || htmlElement.hasTagName(HTMLNames::inputTag)
-            || htmlElement.hasTagName(HTMLNames::insTag)
-            || htmlElement.hasTagName(HTMLNames::kbdTag)
-            || htmlElement.hasTagName(HTMLNames::keygenTag)
-            || htmlElement.hasTagName(HTMLNames::labelTag)
-            || htmlElement.hasTagName(HTMLNames::mapTag)
-            || htmlElement.hasTagName(HTMLNames::markTag)
-            || htmlElement.hasTagName(HTMLNames::meterTag)
-            || htmlElement.hasTagName(HTMLNames::noscriptTag)
-            || htmlElement.hasTagName(HTMLNames::objectTag)
-            || htmlElement.hasTagName(HTMLNames::outputTag)
-            || htmlElement.hasTagName(HTMLNames::progressTag)
-            || htmlElement.hasTagName(HTMLNames::qTag)
-            || htmlElement.hasTagName(HTMLNames::rubyTag)
-            || htmlElement.hasTagName(HTMLNames::sTag)
-            || htmlElement.hasTagName(HTMLNames::sampTag)
-            || htmlElement.hasTagName(HTMLNames::scriptTag)
-            || htmlElement.hasTagName(HTMLNames::selectTag)
-            || htmlElement.hasTagName(HTMLNames::smallTag)
-            || htmlElement.hasTagName(HTMLNames::spanTag)
-            || htmlElement.hasTagName(HTMLNames::strongTag)
-            || htmlElement.hasTagName(HTMLNames::subTag)
-            || htmlElement.hasTagName(HTMLNames::supTag)
-            || htmlElement.hasTagName(HTMLNames::templateTag)
-            || htmlElement.hasTagName(HTMLNames::textareaTag)
-            || htmlElement.hasTagName(HTMLNames::uTag)
-            || htmlElement.hasTagName(HTMLNames::varTag)
-            || htmlElement.hasTagName(HTMLNames::videoTag)
-            || htmlElement.hasTagName(HTMLNames::wbrTag);
-    }
-
-    return false;
-}
-
</del><span class="cx"> bool MathMLTextElement::childShouldCreateRenderer(const Node&amp; child) const
</span><span class="cx"> {
</span><span class="cx">     if (hasTagName(MathMLNames::mspaceTag))
</span><span class="lines">@@ -169,7 +88,7 @@
</span><span class="cx">         return child.isTextNode();
</span><span class="cx"> 
</span><span class="cx">     // The HTML specification defines &lt;mi&gt;, &lt;mo&gt;, &lt;mn&gt;, &lt;ms&gt; and &lt;mtext&gt; as insertion points.
</span><del>-    return isPhrasingContent(child);
</del><ins>+    return isPhrasingContent(child) &amp;&amp; StyledElement::childShouldCreateRenderer(child);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> }
</span></span></pre>
</div>
</div>

</body>
</html>