[html5] r8713 - [giow] (2) getSVGDocument() Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?i [...]

whatwg at whatwg.org whatwg at whatwg.org
Wed Aug 6 11:26:33 PDT 2014


Author: ianh
Date: 2014-08-06 11:26:29 -0700 (Wed, 06 Aug 2014)
New Revision: 8713

Modified:
   complete.html
   index
   source
Log:
[giow] (2) getSVGDocument()
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=25940
Affected topics: DOM APIs, HTML

Modified: complete.html
===================================================================
--- complete.html	2014-08-06 00:09:53 UTC (rev 8712)
+++ complete.html	2014-08-06 18:26:29 UTC (rev 8713)
@@ -291,7 +291,7 @@
   </style><link rel=stylesheet href=status.css><body onload=init()>
   <header id=head class="head with-buttons">
    <p><a href=//www.whatwg.org/ class=logo><img src=/images/logo width=101 alt=WHATWG height=101></a></p>
-   <hgroup><h1 class=allcaps>HTML</h1><h2 id=living-standard-—-last-updated-[date:-01-jan-1901] class="no-num no-toc">Living Standard — Last Updated <span class=pubdate>5 August 2014</span></h2></hgroup>
+   <hgroup><h1 class=allcaps>HTML</h1><h2 id=living-standard-—-last-updated-[date:-01-jan-1901] class="no-num no-toc">Living Standard — Last Updated <span class=pubdate>6 August 2014</span></h2></hgroup>
    
    <nav>
     <div>
@@ -18243,7 +18243,9 @@
 
   <ol><li><p><a href=#update-the-source-set id=the-img-element:update-the-source-set>Update the source set</a> for <var>el</var>.<li><p>If <var>el</var>'s <a href=#source-set id=the-img-element:source-set-2>source set</a> is empty,
    return null as the URL and undefined as the pixel density and abort these steps.<li><p>Otherwise, take <var>el</var>'s <a href=#source-set id=the-img-element:source-set-3>source set</a>
-   and let it be <var>source set</var>.<li><p>In a user agent-specific manner,
+   and let it be <var>source set</var>.<li><p>If an entry <var>b</var> in <var>source set</var> has the same associated density descriptor
+   as an earlier entry <var>a</var> in <var>source set</var>, then remove entry <var>b</var>.
+   Repeat this step until none of the entries in <var>source set</var> have the same associated density descriptor as an earlier entry.<li><p>In a user agent-specific manner,
    choose one <a href=#image-source id=the-img-element:image-source-2>image source</a> from <var>source set</var>.
    Let this be <var>selected source</var>.<li><p>Return <var>selected source</var> and its associated pixel density.</ol>
 
@@ -18270,7 +18272,7 @@
        and <var>source set</var> does not contain an
        <a href=#image-source id=the-img-element:image-source-3>image source</a> with a density descriptor value of 1,
        and no <a href=#image-source id=the-img-element:image-source-4>image source</a> with a width descriptor,
-       append <var>child</var>'s <code id=the-img-element:attr-img-src-11><a href=#attr-img-src>src</a></code> attribute value to <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-8>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
+       append <var>child</var>'s <code id=the-img-element:attr-img-src-11><a href=#attr-img-src>src</a></code> attribute value to <var>source set</var>.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-8>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
 
      <li><p>If <var>child</var> is not a <code id=the-img-element:the-source-element-when-used-with-the-picture-element-7><a href=#the-source-element-when-used-with-the-picture-element>source</a></code> element,
      continue to the next child.
@@ -18283,7 +18285,7 @@
      continue to the next child.<li><p><a href=#parse-a-sizes-attribute id=the-img-element:parse-a-sizes-attribute-2>Parse <var>child</var>'s sizes attribute</a>
      and let <var>source set</var>'s <a href=#source-size-2 id=the-img-element:source-size-2-4>source size</a> be the returned value.<li><p>If <var>child</var> has a <code id=the-img-element:attr-picture-source-type-2><a href=#attr-picture-source-type>type</a></code> attribute,
      and its value is an unknown or unsupported <a href=#mime-type id=the-img-element:mime-type>MIME type</a>,
-     continue to the next child.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-10>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
+     continue to the next child.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities-2>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-10>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
 
    </ol>
 
@@ -18299,56 +18301,51 @@
   parse the value of the element's <code>srcset</code> attribute as follows:</p>
 
   <ol><li><p>Let <var>input</var> be the value passed to this algorithm.<li><p>Let <var>position</var> be a pointer into <var>input</var>,
-   initially pointing at the start of the string.<li><p>Let <var>raw candidates</var> be an initially empty
-   ordered list of URLs with associated unparsed descriptor list.
-   The order of entries in the lists is the order in which entries are added to the lists.<li><p><i>Splitting loop</i>: <a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters>Collect a sequence of characters</a>
+   initially pointing at the start of the string.<li><p>Let <var>candidates</var> be an initially empty <a href=#source-set id=the-img-element:source-set-11>source set</a>.
+   The order of entries in the list is the order in which entries are added to the list.<li><p><i>Splitting loop</i>: <a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters>Collect a sequence of characters</a>
    that are <a href=#space-character id=the-img-element:space-character-8>space characters</a> or U+002C COMMA characters.<li><p>If <var>position</var> is past the end of <var>input</var>,
-   then jump to the step labeled <i>descriptor parser</i>.<li><p><a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters-2>Collect a sequence of characters</a> that are not
+   return <var>candidates</var> and abort these steps.<li><p><a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters-2>Collect a sequence of characters</a> that are not
    <a href=#space-character id=the-img-element:space-character-9>space characters</a>, and let that be <var>url</var>.<li><p>Let <var>descriptors</var> be a new empty list.<li>
 
     <p>If <var>url</var> ends with a U+002C COMMA character (,),
-    follow these substeps:</p>
+    remove all trailing U+002C COMMA characters from <var>url</var>.
+    Otherwise, <a href=#skip-whitespace id=the-img-element:skip-whitespace>skip whitespace</a> and then follow these substeps:</p>
 
-    <ol><li><p>Remove all trailing U+002C COMMA characters from <var>url</var>.<li><p>If <var>url</var> is empty,
-     then jump to the step labeled <i>splitting loop</i>.</ol>
+    <ol><li><p><i>Descriptor tokenizer</i>: Let <var>current descriptor</var> be the empty string.<li><p>Let <var>state</var> be <i>in descriptor</i>.<li>
 
-    <p>Otherwise, follow these substeps:</p>
-
-    <ol><li><p>Let <var>current token</var> be the empty string.<li><p>Let <var>state</var> be <i>start</i>.<li>
-
       <p>Let <var>c</var> be the character at <var>position</var>.
       Do the following depending on the value of <var>state</var>.
       For the purpose of this step, "EOF" is a special character representing
       that <var>position</var> is past the end of <var>input</var>.</p>
 
-      <dl class=switch><dt><i title="">Start</i><dd>
+      <dl class=switch><dt><i title="">In descriptor</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-10>Space character</a><dd><p>If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>
-         and let <var>current token</var> be the empty string.
-         Set <var>state</var> to <i>after token</i>.<dt>U+002C COMMA (,)<dd><p>Advance <var>position</var> to the next character in <var>input</var>.
-         If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>U+0028 LEFT PARANTHESIS (()<dd><p>Append <var>c</var> to <var>current token</var>.
-         Set <var>state</var> to <i>in parens</i>.<dt>EOF<dd><p>If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current token</var>.</dl>
+        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-10>Space character</a><dd><p>If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>
+         and let <var>current descriptor</var> be the empty string.
+         Set <var>state</var> to <i>after descriptor</i>.<dt>U+002C COMMA (,)<dd><p>Advance <var>position</var> to the next character in <var>input</var>.
+         If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>U+0028 LEFT PARANTHESIS (()<dd><p>Append <var>c</var> to <var>current descriptor</var>.
+         Set <var>state</var> to <i>in parens</i>.<dt>EOF<dd><p>If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current descriptor</var>.</dl>
 
        <dt><i title="">In parens</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt>U+0029 RIGHT PARENTHESIS ())<dd><p>Append <var>c</var> to <var>current token</var>.
-         Set <var>state</var> to <i>start</i>.<dt>EOF<dd><p>Append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current token</var>.</dl>
+        <dl class=switch><dt>U+0029 RIGHT PARENTHESIS ())<dd><p>Append <var>c</var> to <var>current descriptor</var>.
+         Set <var>state</var> to <i>in descriptor</i>.<dt>EOF<dd><p>Append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current descriptor</var>.</dl>
 
-       <dt><i title="">After token</i><dd>
+       <dt><i title="">After descriptor</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-11>Space character</a><dd><p>Stay in this state.<dt>EOF<dd><p>Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Set <var>state</var> to <i>start</i>.
+        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-11>Space character</a><dd><p>Stay in this state.<dt>EOF<dd><p>Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Set <var>state</var> to <i>in descriptor</i>.
          Set <var>position</var> to the <em>previous</em> character in <var>input</var>.</dl>
 
        </dl>
@@ -18356,68 +18353,60 @@
       <p>Advance <var>position</var> to the next character in <var>input</var>.
       Repeat this step.</p>
 
+      <p class=note>In order to be compatible with future additions,
+      this algorithm supports multiple descriptors and descriptors with parens.</p>
+
      </ol>
 
-   <li><p><i>Add candidate</i>: Add <var>url</var> to <var>raw candidates</var>,
-   associated with <var>descriptors</var>.<li><p>Return to the step labeled <i>splitting loop</i>.<li><p><i>Descriptor parser</i>:
-   Let <var>candidates</var> be an initially empty <a href=#source-set id=the-img-element:source-set-11>source set</a>.
-   The order of entries in the list is the order in which entries are added to the list.<li>
+   <li><p><i>Descriptor parser</i>: Let <var>error</var> be <i>no</i>.<li><p>Let <var>width</var> be <i>absent</i>.<li><p>Let <var>density</var> be <i>absent</i>.<li><p>Let <var>future-compat-h</var> be <i>absent</i>.<li>
 
-    <p>For each entry in <var>raw candidates</var> with URL <var>url</var>
-    associated with the unparsed descriptor list <var>descriptor list</var>,
-    run these substeps:</p>
+    <p>For each descriptor in <var>descriptors</var>,
+    run the appropriate set of steps from the following list:</p>
 
-    <ol><li><p>Let <var>error</var> be <i>no</i>.<li><p>Let <var>width</var> be <i>absent</i>.<li><p>Let <var>density</var> be <i>absent</i>.<li><p>Let <var>future-compat-h</var> be <i>absent</i>.<li>
+    <dl class=switch><dt>If the descriptor consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-2>valid non-negative integer</a>
+     followed by a U+0077 LATIN SMALL LETTER W character<dd>
 
-      <p>For each token in <var>descriptor list</var>,
-      run the appropriate set of steps from the following list:</p>
+      <ol><li><p>If <var>width</var> and <var>density</var>
+       are not both <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a> to the descriptor.
+       If the result is zero, let <var>error</var> be <i>yes</i>.
+       Otherwise, let <var>width</var> be the result.</ol>
 
-      <dl class=switch><dt>If the token consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-2>valid non-negative integer</a>
-       followed by a U+0077 LATIN SMALL LETTER W character<dd>
+     <dt>If the descriptor consists of a <a href=#valid-floating-point-number id=the-img-element:valid-floating-point-number-2>valid floating-point number</a>
+     followed by a U+0078 LATIN SMALL LETTER X character<dd>
 
-        <ol><li><p>If <var>width</var> and <var>density</var>
-         are not both <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a> to the token.
-         If the result is zero, let <var>error</var> be <i>yes</i>.
-         Otherwise, let <var>width</var> be the result.</ol>
+      <ol><li><p>If <var>width</var>, <var>density</var> and <var>future-compat-h</var>
+       are not all <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li>
 
-       <dt>If the token consists of a <a href=#valid-floating-point-number id=the-img-element:valid-floating-point-number-2>valid floating-point number</a>
-       followed by a U+0078 LATIN SMALL LETTER X character<dd>
+        <p>Apply the <a href=#rules-for-parsing-floating-point-number-values id=the-img-element:rules-for-parsing-floating-point-number-values>rules for parsing floating-point number values</a> to the descriptor.
+        If the result is less than zero, let <var>error</var> be <i>yes</i>.
+        Otherwise, let <var>density</var> be the result.</p>
 
-        <ol><li><p>If <var>width</var>, <var>density</var> and <var>future-compat-h</var>
-         are not all <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li>
+        <p class=note>If <var>density</var> is zero,
+        the intrinsic dimensions will be infinite.
+        User agents are expected to have limits in how big images can be rendered,
+        which is allowed by the <a href=#hardwareLimitations>hardware limitations</a> clause.</p>
 
-          <p>Apply the <a href=#rules-for-parsing-floating-point-number-values id=the-img-element:rules-for-parsing-floating-point-number-values>rules for parsing floating-point number values</a> to the token.
-          If the result is less than zero, let <var>error</var> be <i>yes</i>.
-          Otherwise, let <var>density</var> be the result.</p>
+       </ol>
 
-          <p class=note>If <var>density</var> is zero,
-          the intrinsic dimensions will be infinite.
-          User agents are expected to have limits in how big images can be rendered,
-          which is allowed by the <a href=#hardwareLimitations>hardware limitations</a> clause.</p>
+     <dt>If the descriptor consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-3>valid non-negative integer</a>
+     followed by a U+0068 LATIN SMALL LETTER H character<dd>
 
-         </ol>
+      <ol><li><p>If <var>future-compat-h</var> and <var>density</var>
+       are not both <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers-2>rules for parsing non-negative integers</a> to the descriptor.
+       If the result is zero, let <var>error</var> be <i>yes</i>.
+       Otherwise, let <var>future-compat-h</var> be the result.</ol>
 
-       <dt>If the token consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-3>valid non-negative integer</a>
-       followed by a U+0068 LATIN SMALL LETTER H character<dd>
+     </dl>
 
-        <ol><li><p>If <var>future-compat-h</var> and <var>density</var>
-         are not both <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers-2>rules for parsing non-negative integers</a> to the token.
-         If the result is zero, let <var>error</var> be <i>yes</i>.
-         Otherwise, let <var>future-compat-h</var> be the result.</ol>
+   <li><p>If <var>error</var> is still <i>no</i>,
+   then add a new <a href=#image-source id=the-img-element:image-source-7>image source</a> to <var>candidates</var>
+   whose URL is <var>url</var>,
+   associated with a width <var>width</var> if not <i>absent</i>
+   and a pixel density <var>density</var> if not <i>absent</i>.<li><p>Return to the step labeled <i>splitting loop</i>.</ol>
 
-       </dl>
-
-     <li><p>If <var>error</var> is still <i>no</i>,
-     then add a new <a href=#image-source id=the-img-element:image-source-7>image source</a> to <var>candidates</var>
-     whose URL is <var>url</var>,
-     associated with a width <var>width</var> if not <i>absent</i>
-     and a pixel density <var>density</var> if not <i>absent</i>.</ol>
-
-   <li><p>Return <var>candidates</var>.</ol>
-
   <p>When asked to <dfn id=parse-a-sizes-attribute>parse a sizes attribute</dfn> from an element,
   <a href=#parse-a-comma-separated-list-of-component-values id=the-img-element:parse-a-comma-separated-list-of-component-values>parse a comma-separated list of component values</a>
   from the value of the element's <code>sizes</code> attribute
@@ -20296,6 +20285,7 @@
            attribute DOMString <a href=#dom-embed-type id=the-embed-element:dom-embed-type>type</a>;
            attribute DOMString <a href=#dom-dim-width id=the-embed-element:dom-dim-width>width</a>;
            attribute DOMString <a href=#dom-dim-height id=the-embed-element:dom-dim-height>height</a>;
+  <a href=#document id=the-embed-element:document>Document</a> <a href=#dom-embed-getsvgdocument id=the-embed-element:dom-embed-getsvgdocument>getSVGDocument</a>();
   <a href=#dom-embed-caller id=the-embed-element:dom-embed-caller>legacycaller</a> any (any... arguments);
 
   // <a href="#HTMLEmbedElement-partial">also has obsolete members</a>
@@ -20336,7 +20326,7 @@
   active</dfn> when the following conditions are all met simultaneously:</p>
 
   <ul class=brief><li>The element is <a href=#in-a-document id=the-embed-element:in-a-document>in a <code>Document</code></a> or was <a href=#in-a-document id=the-embed-element:in-a-document-2>in a <code>Document</code></a> the last time the <a href=#event-loop id=the-embed-element:event-loop>event loop</a>
-   reached step 1.<li>The element's <code id=the-embed-element:document><a href=#document>Document</a></code> is <a href=#fully-active id=the-embed-element:fully-active>fully active</a>.<li>The element has either a <code id=the-embed-element:attr-embed-src-6><a href=#attr-embed-src>src</a></code> attribute set or a <code id=the-embed-element:attr-embed-type-5><a href=#attr-embed-type>type</a></code> attribute set (or both).<li>The element's <code id=the-embed-element:attr-embed-src-7><a href=#attr-embed-src>src</a></code> attribute is either absent or its value
+   reached step 1.<li>The element's <code id=the-embed-element:document-2><a href=#document>Document</a></code> is <a href=#fully-active id=the-embed-element:fully-active>fully active</a>.<li>The element has either a <code id=the-embed-element:attr-embed-src-6><a href=#attr-embed-src>src</a></code> attribute set or a <code id=the-embed-element:attr-embed-type-5><a href=#attr-embed-type>type</a></code> attribute set (or both).<li>The element's <code id=the-embed-element:attr-embed-src-7><a href=#attr-embed-src>src</a></code> attribute is either absent or its value
    is not the empty string.<li>The element is not a descendant of a <a href=#media-element id=the-embed-element:media-element-2>media element</a>.<li>The element is not a descendant of an <code id=the-embed-element:the-object-element-2><a href=#the-object-element>object</a></code> element that is not showing its
    <a href=#fallback-content id=the-embed-element:fallback-content-2>fallback content</a>.<li>The element is <a href=#being-rendered id=the-embed-element:being-rendered>being rendered</a>, or was <a href=#being-rendered id=the-embed-element:being-rendered-2>being rendered</a> the last time
    the <a href=#event-loop id=the-embed-element:event-loop-2>event loop</a> reached step 1.</ul>
@@ -20457,7 +20447,7 @@
   <a href=#plugin id=the-embed-element:plugin-10>plugin</a> that had been instantiated for that element must be unloaded.</p>
 
   <p id=sandboxPluginEmbed>When a <a href=#plugin id=the-embed-element:plugin-11>plugin</a> is to be instantiated but it cannot be <a href=#concept-plugin-secure id=the-embed-element:concept-plugin-secure>secured</a> and the <a href=#sandboxed-plugins-browsing-context-flag id=the-embed-element:sandboxed-plugins-browsing-context-flag>sandboxed plugins browsing context
-  flag</a> is set on the <code id=the-embed-element:the-embed-element-16><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-2><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set id=the-embed-element:active-sandboxing-flag-set>active
+  flag</a> is set on the <code id=the-embed-element:the-embed-element-16><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-3><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set id=the-embed-element:active-sandboxing-flag-set>active
   sandboxing flag set</a>, then the user agent must not instantiate the <a href=#plugin id=the-embed-element:plugin-12>plugin</a>, and
   must instead render the <code id=the-embed-element:the-embed-element-17><a href=#the-embed-element>embed</a></code> element in a manner that conveys that the
   <a href=#plugin id=the-embed-element:plugin-13>plugin</a> was disabled. The user agent may offer the user the option to override the
@@ -20510,13 +20500,35 @@
 
   <p>The <code id=the-embed-element:the-embed-element-26><a href=#the-embed-element>embed</a></code> element supports <a href=#dimension-attributes id=the-embed-element:dimension-attributes>dimension attributes</a>.</p>
 
+
+  <dl class=domintro><dt><var>doc</var> = <var>embed</var> . <code id=the-embed-element:dom-embed-getsvgdocument-2><a href=#dom-embed-getsvgdocument>getSVGDocument</a></code>()<dd>
+
+    <p>Returns the <code id=the-embed-element:document-4><a href=#document>Document</a></code> object, in the case of <code id=the-embed-element:the-embed-element-27><a href=#the-embed-element>embed</a></code> being used to embed SVG images.</p>
+
+   </dl>
+
   
 
+  <p>The <dfn id=dom-embed-getsvgdocument><code>getSVGDocument()</code></dfn> method must run
+  the following steps:</p>
+
+  <ol><li><p>If the element has no <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-8>nested browsing context</a>, then return null and abort
+   these steps.<li><p>If the <a href=#active-document id=the-embed-element:active-document-3>active document</a> of the <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-9>nested browsing context</a> does not
+   have the <a href=#same-origin id=the-embed-element:same-origin>same</a> <a href=#effective-script-origin id=the-embed-element:effective-script-origin>effective script origin</a> as the
+   <code id=the-embed-element:the-embed-element-28><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-5><a href=#document>Document</a></code>, then return null and abort these
+   steps.<li><p>If the <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-10>nested browsing context</a>'s <a href=#active-document id=the-embed-element:active-document-4>active document</a> was created by
+   the <a href=#read-xml id=the-embed-element:read-xml>page load processing model for XML files</a> section because
+   <span>the sniffed type of the resource</span> in the <a href=#navigate id=the-embed-element:navigate-2>navigate</a> algorithm was
+   <code id=the-embed-element:image/svg+xml><a href=#image/svg+xml>image/svg+xml</a></code>, then return that <code id=the-embed-element:document-6><a href=#document>Document</a></code> object and abort these
+   steps.<li><p>Otherwise, return null.</ol>
+
   <p>The IDL attributes <dfn id=dom-embed-src><code>src</code></dfn> and <dfn id=dom-embed-type><code>type</code></dfn> each must <a href=#reflect id=the-embed-element:reflect>reflect</a> the respective
   content attributes of the same name.</p>
 
   
 
+
+
   <div class=example>
 
    <p>Here's a way to embed a resource that requires a proprietary plugin, like Flash:</p>

Modified: index
===================================================================
--- index	2014-08-06 00:09:53 UTC (rev 8712)
+++ index	2014-08-06 18:26:29 UTC (rev 8713)
@@ -291,7 +291,7 @@
   </style><link rel=stylesheet href=status.css><body onload=init()>
   <header id=head class="head with-buttons">
    <p><a href=//www.whatwg.org/ class=logo><img src=/images/logo width=101 alt=WHATWG height=101></a></p>
-   <hgroup><h1 class=allcaps>HTML</h1><h2 id=living-standard-—-last-updated-[date:-01-jan-1901] class="no-num no-toc">Living Standard — Last Updated <span class=pubdate>5 August 2014</span></h2></hgroup>
+   <hgroup><h1 class=allcaps>HTML</h1><h2 id=living-standard-—-last-updated-[date:-01-jan-1901] class="no-num no-toc">Living Standard — Last Updated <span class=pubdate>6 August 2014</span></h2></hgroup>
    
    <nav>
     <div>
@@ -18243,7 +18243,9 @@
 
   <ol><li><p><a href=#update-the-source-set id=the-img-element:update-the-source-set>Update the source set</a> for <var>el</var>.<li><p>If <var>el</var>'s <a href=#source-set id=the-img-element:source-set-2>source set</a> is empty,
    return null as the URL and undefined as the pixel density and abort these steps.<li><p>Otherwise, take <var>el</var>'s <a href=#source-set id=the-img-element:source-set-3>source set</a>
-   and let it be <var>source set</var>.<li><p>In a user agent-specific manner,
+   and let it be <var>source set</var>.<li><p>If an entry <var>b</var> in <var>source set</var> has the same associated density descriptor
+   as an earlier entry <var>a</var> in <var>source set</var>, then remove entry <var>b</var>.
+   Repeat this step until none of the entries in <var>source set</var> have the same associated density descriptor as an earlier entry.<li><p>In a user agent-specific manner,
    choose one <a href=#image-source id=the-img-element:image-source-2>image source</a> from <var>source set</var>.
    Let this be <var>selected source</var>.<li><p>Return <var>selected source</var> and its associated pixel density.</ol>
 
@@ -18270,7 +18272,7 @@
        and <var>source set</var> does not contain an
        <a href=#image-source id=the-img-element:image-source-3>image source</a> with a density descriptor value of 1,
        and no <a href=#image-source id=the-img-element:image-source-4>image source</a> with a width descriptor,
-       append <var>child</var>'s <code id=the-img-element:attr-img-src-11><a href=#attr-img-src>src</a></code> attribute value to <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-8>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
+       append <var>child</var>'s <code id=the-img-element:attr-img-src-11><a href=#attr-img-src>src</a></code> attribute value to <var>source set</var>.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-8>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
 
      <li><p>If <var>child</var> is not a <code id=the-img-element:the-source-element-when-used-with-the-picture-element-7><a href=#the-source-element-when-used-with-the-picture-element>source</a></code> element,
      continue to the next child.
@@ -18283,7 +18285,7 @@
      continue to the next child.<li><p><a href=#parse-a-sizes-attribute id=the-img-element:parse-a-sizes-attribute-2>Parse <var>child</var>'s sizes attribute</a>
      and let <var>source set</var>'s <a href=#source-size-2 id=the-img-element:source-size-2-4>source size</a> be the returned value.<li><p>If <var>child</var> has a <code id=the-img-element:attr-picture-source-type-2><a href=#attr-picture-source-type>type</a></code> attribute,
      and its value is an unknown or unsupported <a href=#mime-type id=the-img-element:mime-type>MIME type</a>,
-     continue to the next child.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-10>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
+     continue to the next child.<li><p><a href=#normalize-the-source-densities id=the-img-element:normalize-the-source-densities-2>Normalize the source densities</a> of <var>source set</var>.<li><p>Let <var>el</var>'s <a href=#source-set id=the-img-element:source-set-10>source set</a> be <var>source set</var>.<li><p>Abort this algorithm.</ol>
 
    </ol>
 
@@ -18299,56 +18301,51 @@
   parse the value of the element's <code>srcset</code> attribute as follows:</p>
 
   <ol><li><p>Let <var>input</var> be the value passed to this algorithm.<li><p>Let <var>position</var> be a pointer into <var>input</var>,
-   initially pointing at the start of the string.<li><p>Let <var>raw candidates</var> be an initially empty
-   ordered list of URLs with associated unparsed descriptor list.
-   The order of entries in the lists is the order in which entries are added to the lists.<li><p><i>Splitting loop</i>: <a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters>Collect a sequence of characters</a>
+   initially pointing at the start of the string.<li><p>Let <var>candidates</var> be an initially empty <a href=#source-set id=the-img-element:source-set-11>source set</a>.
+   The order of entries in the list is the order in which entries are added to the list.<li><p><i>Splitting loop</i>: <a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters>Collect a sequence of characters</a>
    that are <a href=#space-character id=the-img-element:space-character-8>space characters</a> or U+002C COMMA characters.<li><p>If <var>position</var> is past the end of <var>input</var>,
-   then jump to the step labeled <i>descriptor parser</i>.<li><p><a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters-2>Collect a sequence of characters</a> that are not
+   return <var>candidates</var> and abort these steps.<li><p><a href=#collect-a-sequence-of-characters id=the-img-element:collect-a-sequence-of-characters-2>Collect a sequence of characters</a> that are not
    <a href=#space-character id=the-img-element:space-character-9>space characters</a>, and let that be <var>url</var>.<li><p>Let <var>descriptors</var> be a new empty list.<li>
 
     <p>If <var>url</var> ends with a U+002C COMMA character (,),
-    follow these substeps:</p>
+    remove all trailing U+002C COMMA characters from <var>url</var>.
+    Otherwise, <a href=#skip-whitespace id=the-img-element:skip-whitespace>skip whitespace</a> and then follow these substeps:</p>
 
-    <ol><li><p>Remove all trailing U+002C COMMA characters from <var>url</var>.<li><p>If <var>url</var> is empty,
-     then jump to the step labeled <i>splitting loop</i>.</ol>
+    <ol><li><p><i>Descriptor tokenizer</i>: Let <var>current descriptor</var> be the empty string.<li><p>Let <var>state</var> be <i>in descriptor</i>.<li>
 
-    <p>Otherwise, follow these substeps:</p>
-
-    <ol><li><p>Let <var>current token</var> be the empty string.<li><p>Let <var>state</var> be <i>start</i>.<li>
-
       <p>Let <var>c</var> be the character at <var>position</var>.
       Do the following depending on the value of <var>state</var>.
       For the purpose of this step, "EOF" is a special character representing
       that <var>position</var> is past the end of <var>input</var>.</p>
 
-      <dl class=switch><dt><i title="">Start</i><dd>
+      <dl class=switch><dt><i title="">In descriptor</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-10>Space character</a><dd><p>If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>
-         and let <var>current token</var> be the empty string.
-         Set <var>state</var> to <i>after token</i>.<dt>U+002C COMMA (,)<dd><p>Advance <var>position</var> to the next character in <var>input</var>.
-         If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>U+0028 LEFT PARANTHESIS (()<dd><p>Append <var>c</var> to <var>current token</var>.
-         Set <var>state</var> to <i>in parens</i>.<dt>EOF<dd><p>If <var>current token</var> is not empty,
-         append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current token</var>.</dl>
+        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-10>Space character</a><dd><p>If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>
+         and let <var>current descriptor</var> be the empty string.
+         Set <var>state</var> to <i>after descriptor</i>.<dt>U+002C COMMA (,)<dd><p>Advance <var>position</var> to the next character in <var>input</var>.
+         If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>U+0028 LEFT PARANTHESIS (()<dd><p>Append <var>c</var> to <var>current descriptor</var>.
+         Set <var>state</var> to <i>in parens</i>.<dt>EOF<dd><p>If <var>current descriptor</var> is not empty,
+         append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current descriptor</var>.</dl>
 
        <dt><i title="">In parens</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt>U+0029 RIGHT PARENTHESIS ())<dd><p>Append <var>c</var> to <var>current token</var>.
-         Set <var>state</var> to <i>start</i>.<dt>EOF<dd><p>Append <var>current token</var> to <var>descriptors</var>.
-         Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current token</var>.</dl>
+        <dl class=switch><dt>U+0029 RIGHT PARENTHESIS ())<dd><p>Append <var>c</var> to <var>current descriptor</var>.
+         Set <var>state</var> to <i>in descriptor</i>.<dt>EOF<dd><p>Append <var>current descriptor</var> to <var>descriptors</var>.
+         Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Append <var>c</var> to <var>current descriptor</var>.</dl>
 
-       <dt><i title="">After token</i><dd>
+       <dt><i title="">After descriptor</i><dd>
 
         <p>Do the following, depending on the value of <var>c</var>:</p>
 
-        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-11>Space character</a><dd><p>Stay in this state.<dt>EOF<dd><p>Jump to the step labeled <i>add candidate</i>.<dt>Anything else<dd><p>Set <var>state</var> to <i>start</i>.
+        <dl class=switch><dt><a href=#space-character id=the-img-element:space-character-11>Space character</a><dd><p>Stay in this state.<dt>EOF<dd><p>Jump to the step labeled <i>descriptor parser</i>.<dt>Anything else<dd><p>Set <var>state</var> to <i>in descriptor</i>.
          Set <var>position</var> to the <em>previous</em> character in <var>input</var>.</dl>
 
        </dl>
@@ -18356,68 +18353,60 @@
       <p>Advance <var>position</var> to the next character in <var>input</var>.
       Repeat this step.</p>
 
+      <p class=note>In order to be compatible with future additions,
+      this algorithm supports multiple descriptors and descriptors with parens.</p>
+
      </ol>
 
-   <li><p><i>Add candidate</i>: Add <var>url</var> to <var>raw candidates</var>,
-   associated with <var>descriptors</var>.<li><p>Return to the step labeled <i>splitting loop</i>.<li><p><i>Descriptor parser</i>:
-   Let <var>candidates</var> be an initially empty <a href=#source-set id=the-img-element:source-set-11>source set</a>.
-   The order of entries in the list is the order in which entries are added to the list.<li>
+   <li><p><i>Descriptor parser</i>: Let <var>error</var> be <i>no</i>.<li><p>Let <var>width</var> be <i>absent</i>.<li><p>Let <var>density</var> be <i>absent</i>.<li><p>Let <var>future-compat-h</var> be <i>absent</i>.<li>
 
-    <p>For each entry in <var>raw candidates</var> with URL <var>url</var>
-    associated with the unparsed descriptor list <var>descriptor list</var>,
-    run these substeps:</p>
+    <p>For each descriptor in <var>descriptors</var>,
+    run the appropriate set of steps from the following list:</p>
 
-    <ol><li><p>Let <var>error</var> be <i>no</i>.<li><p>Let <var>width</var> be <i>absent</i>.<li><p>Let <var>density</var> be <i>absent</i>.<li><p>Let <var>future-compat-h</var> be <i>absent</i>.<li>
+    <dl class=switch><dt>If the descriptor consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-2>valid non-negative integer</a>
+     followed by a U+0077 LATIN SMALL LETTER W character<dd>
 
-      <p>For each token in <var>descriptor list</var>,
-      run the appropriate set of steps from the following list:</p>
+      <ol><li><p>If <var>width</var> and <var>density</var>
+       are not both <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a> to the descriptor.
+       If the result is zero, let <var>error</var> be <i>yes</i>.
+       Otherwise, let <var>width</var> be the result.</ol>
 
-      <dl class=switch><dt>If the token consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-2>valid non-negative integer</a>
-       followed by a U+0077 LATIN SMALL LETTER W character<dd>
+     <dt>If the descriptor consists of a <a href=#valid-floating-point-number id=the-img-element:valid-floating-point-number-2>valid floating-point number</a>
+     followed by a U+0078 LATIN SMALL LETTER X character<dd>
 
-        <ol><li><p>If <var>width</var> and <var>density</var>
-         are not both <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a> to the token.
-         If the result is zero, let <var>error</var> be <i>yes</i>.
-         Otherwise, let <var>width</var> be the result.</ol>
+      <ol><li><p>If <var>width</var>, <var>density</var> and <var>future-compat-h</var>
+       are not all <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li>
 
-       <dt>If the token consists of a <a href=#valid-floating-point-number id=the-img-element:valid-floating-point-number-2>valid floating-point number</a>
-       followed by a U+0078 LATIN SMALL LETTER X character<dd>
+        <p>Apply the <a href=#rules-for-parsing-floating-point-number-values id=the-img-element:rules-for-parsing-floating-point-number-values>rules for parsing floating-point number values</a> to the descriptor.
+        If the result is less than zero, let <var>error</var> be <i>yes</i>.
+        Otherwise, let <var>density</var> be the result.</p>
 
-        <ol><li><p>If <var>width</var>, <var>density</var> and <var>future-compat-h</var>
-         are not all <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li>
+        <p class=note>If <var>density</var> is zero,
+        the intrinsic dimensions will be infinite.
+        User agents are expected to have limits in how big images can be rendered,
+        which is allowed by the <a href=#hardwareLimitations>hardware limitations</a> clause.</p>
 
-          <p>Apply the <a href=#rules-for-parsing-floating-point-number-values id=the-img-element:rules-for-parsing-floating-point-number-values>rules for parsing floating-point number values</a> to the token.
-          If the result is less than zero, let <var>error</var> be <i>yes</i>.
-          Otherwise, let <var>density</var> be the result.</p>
+       </ol>
 
-          <p class=note>If <var>density</var> is zero,
-          the intrinsic dimensions will be infinite.
-          User agents are expected to have limits in how big images can be rendered,
-          which is allowed by the <a href=#hardwareLimitations>hardware limitations</a> clause.</p>
+     <dt>If the descriptor consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-3>valid non-negative integer</a>
+     followed by a U+0068 LATIN SMALL LETTER H character<dd>
 
-         </ol>
+      <ol><li><p>If <var>future-compat-h</var> and <var>density</var>
+       are not both <i>absent</i>,
+       then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers-2>rules for parsing non-negative integers</a> to the descriptor.
+       If the result is zero, let <var>error</var> be <i>yes</i>.
+       Otherwise, let <var>future-compat-h</var> be the result.</ol>
 
-       <dt>If the token consists of a <a href=#valid-non-negative-integer id=the-img-element:valid-non-negative-integer-3>valid non-negative integer</a>
-       followed by a U+0068 LATIN SMALL LETTER H character<dd>
+     </dl>
 
-        <ol><li><p>If <var>future-compat-h</var> and <var>density</var>
-         are not both <i>absent</i>,
-         then let <var>error</var> be <i>yes</i>.<li><p>Apply the <a href=#rules-for-parsing-non-negative-integers id=the-img-element:rules-for-parsing-non-negative-integers-2>rules for parsing non-negative integers</a> to the token.
-         If the result is zero, let <var>error</var> be <i>yes</i>.
-         Otherwise, let <var>future-compat-h</var> be the result.</ol>
+   <li><p>If <var>error</var> is still <i>no</i>,
+   then add a new <a href=#image-source id=the-img-element:image-source-7>image source</a> to <var>candidates</var>
+   whose URL is <var>url</var>,
+   associated with a width <var>width</var> if not <i>absent</i>
+   and a pixel density <var>density</var> if not <i>absent</i>.<li><p>Return to the step labeled <i>splitting loop</i>.</ol>
 
-       </dl>
-
-     <li><p>If <var>error</var> is still <i>no</i>,
-     then add a new <a href=#image-source id=the-img-element:image-source-7>image source</a> to <var>candidates</var>
-     whose URL is <var>url</var>,
-     associated with a width <var>width</var> if not <i>absent</i>
-     and a pixel density <var>density</var> if not <i>absent</i>.</ol>
-
-   <li><p>Return <var>candidates</var>.</ol>
-
   <p>When asked to <dfn id=parse-a-sizes-attribute>parse a sizes attribute</dfn> from an element,
   <a href=#parse-a-comma-separated-list-of-component-values id=the-img-element:parse-a-comma-separated-list-of-component-values>parse a comma-separated list of component values</a>
   from the value of the element's <code>sizes</code> attribute
@@ -20296,6 +20285,7 @@
            attribute DOMString <a href=#dom-embed-type id=the-embed-element:dom-embed-type>type</a>;
            attribute DOMString <a href=#dom-dim-width id=the-embed-element:dom-dim-width>width</a>;
            attribute DOMString <a href=#dom-dim-height id=the-embed-element:dom-dim-height>height</a>;
+  <a href=#document id=the-embed-element:document>Document</a> <a href=#dom-embed-getsvgdocument id=the-embed-element:dom-embed-getsvgdocument>getSVGDocument</a>();
   <a href=#dom-embed-caller id=the-embed-element:dom-embed-caller>legacycaller</a> any (any... arguments);
 
   // <a href="#HTMLEmbedElement-partial">also has obsolete members</a>
@@ -20336,7 +20326,7 @@
   active</dfn> when the following conditions are all met simultaneously:</p>
 
   <ul class=brief><li>The element is <a href=#in-a-document id=the-embed-element:in-a-document>in a <code>Document</code></a> or was <a href=#in-a-document id=the-embed-element:in-a-document-2>in a <code>Document</code></a> the last time the <a href=#event-loop id=the-embed-element:event-loop>event loop</a>
-   reached step 1.<li>The element's <code id=the-embed-element:document><a href=#document>Document</a></code> is <a href=#fully-active id=the-embed-element:fully-active>fully active</a>.<li>The element has either a <code id=the-embed-element:attr-embed-src-6><a href=#attr-embed-src>src</a></code> attribute set or a <code id=the-embed-element:attr-embed-type-5><a href=#attr-embed-type>type</a></code> attribute set (or both).<li>The element's <code id=the-embed-element:attr-embed-src-7><a href=#attr-embed-src>src</a></code> attribute is either absent or its value
+   reached step 1.<li>The element's <code id=the-embed-element:document-2><a href=#document>Document</a></code> is <a href=#fully-active id=the-embed-element:fully-active>fully active</a>.<li>The element has either a <code id=the-embed-element:attr-embed-src-6><a href=#attr-embed-src>src</a></code> attribute set or a <code id=the-embed-element:attr-embed-type-5><a href=#attr-embed-type>type</a></code> attribute set (or both).<li>The element's <code id=the-embed-element:attr-embed-src-7><a href=#attr-embed-src>src</a></code> attribute is either absent or its value
    is not the empty string.<li>The element is not a descendant of a <a href=#media-element id=the-embed-element:media-element-2>media element</a>.<li>The element is not a descendant of an <code id=the-embed-element:the-object-element-2><a href=#the-object-element>object</a></code> element that is not showing its
    <a href=#fallback-content id=the-embed-element:fallback-content-2>fallback content</a>.<li>The element is <a href=#being-rendered id=the-embed-element:being-rendered>being rendered</a>, or was <a href=#being-rendered id=the-embed-element:being-rendered-2>being rendered</a> the last time
    the <a href=#event-loop id=the-embed-element:event-loop-2>event loop</a> reached step 1.</ul>
@@ -20457,7 +20447,7 @@
   <a href=#plugin id=the-embed-element:plugin-10>plugin</a> that had been instantiated for that element must be unloaded.</p>
 
   <p id=sandboxPluginEmbed>When a <a href=#plugin id=the-embed-element:plugin-11>plugin</a> is to be instantiated but it cannot be <a href=#concept-plugin-secure id=the-embed-element:concept-plugin-secure>secured</a> and the <a href=#sandboxed-plugins-browsing-context-flag id=the-embed-element:sandboxed-plugins-browsing-context-flag>sandboxed plugins browsing context
-  flag</a> is set on the <code id=the-embed-element:the-embed-element-16><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-2><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set id=the-embed-element:active-sandboxing-flag-set>active
+  flag</a> is set on the <code id=the-embed-element:the-embed-element-16><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-3><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set id=the-embed-element:active-sandboxing-flag-set>active
   sandboxing flag set</a>, then the user agent must not instantiate the <a href=#plugin id=the-embed-element:plugin-12>plugin</a>, and
   must instead render the <code id=the-embed-element:the-embed-element-17><a href=#the-embed-element>embed</a></code> element in a manner that conveys that the
   <a href=#plugin id=the-embed-element:plugin-13>plugin</a> was disabled. The user agent may offer the user the option to override the
@@ -20510,13 +20500,35 @@
 
   <p>The <code id=the-embed-element:the-embed-element-26><a href=#the-embed-element>embed</a></code> element supports <a href=#dimension-attributes id=the-embed-element:dimension-attributes>dimension attributes</a>.</p>
 
+
+  <dl class=domintro><dt><var>doc</var> = <var>embed</var> . <code id=the-embed-element:dom-embed-getsvgdocument-2><a href=#dom-embed-getsvgdocument>getSVGDocument</a></code>()<dd>
+
+    <p>Returns the <code id=the-embed-element:document-4><a href=#document>Document</a></code> object, in the case of <code id=the-embed-element:the-embed-element-27><a href=#the-embed-element>embed</a></code> being used to embed SVG images.</p>
+
+   </dl>
+
   
 
+  <p>The <dfn id=dom-embed-getsvgdocument><code>getSVGDocument()</code></dfn> method must run
+  the following steps:</p>
+
+  <ol><li><p>If the element has no <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-8>nested browsing context</a>, then return null and abort
+   these steps.<li><p>If the <a href=#active-document id=the-embed-element:active-document-3>active document</a> of the <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-9>nested browsing context</a> does not
+   have the <a href=#same-origin id=the-embed-element:same-origin>same</a> <a href=#effective-script-origin id=the-embed-element:effective-script-origin>effective script origin</a> as the
+   <code id=the-embed-element:the-embed-element-28><a href=#the-embed-element>embed</a></code> element's <code id=the-embed-element:document-5><a href=#document>Document</a></code>, then return null and abort these
+   steps.<li><p>If the <a href=#nested-browsing-context id=the-embed-element:nested-browsing-context-10>nested browsing context</a>'s <a href=#active-document id=the-embed-element:active-document-4>active document</a> was created by
+   the <a href=#read-xml id=the-embed-element:read-xml>page load processing model for XML files</a> section because
+   <span>the sniffed type of the resource</span> in the <a href=#navigate id=the-embed-element:navigate-2>navigate</a> algorithm was
+   <code id=the-embed-element:image/svg+xml><a href=#image/svg+xml>image/svg+xml</a></code>, then return that <code id=the-embed-element:document-6><a href=#document>Document</a></code> object and abort these
+   steps.<li><p>Otherwise, return null.</ol>
+
   <p>The IDL attributes <dfn id=dom-embed-src><code>src</code></dfn> and <dfn id=dom-embed-type><code>type</code></dfn> each must <a href=#reflect id=the-embed-element:reflect>reflect</a> the respective
   content attributes of the same name.</p>
 
   
 
+
+
   <div class=example>
 
    <p>Here's a way to embed a resource that requires a proprietary plugin, like Flash:</p>

Modified: source
===================================================================
--- source	2014-08-06 00:09:53 UTC (rev 8712)
+++ source	2014-08-06 18:26:29 UTC (rev 8713)
@@ -25398,6 +25398,7 @@
            attribute DOMString <span data-x="dom-embed-type">type</span>;
            attribute DOMString <span data-x="dom-dim-width">width</span>;
            attribute DOMString <span data-x="dom-dim-height">height</span>;
+  <span>Document</span> <span data-x="dom-embed-getSVGDocument">getSVGDocument</span>();
   <span data-x="dom-embed-caller">legacycaller</span> any (any... arguments);
 };</pre>
     <div w-nodev>
@@ -25704,13 +25705,51 @@
 
   <p>The <code>embed</code> element supports <span>dimension attributes</span>.</p>
 
+<!--TOPIC:DOM APIs-->
+  <dl class="domintro">
+
+   <dt><var>doc</var> = <var>embed</var> . <code subdfn data-x="dom-embed-getSVGDocument">getSVGDocument</code>()</dt>
+
+   <dd>
+
+    <p>Returns the <code>Document</code> object, in the case of <code>embed</code> being used to embed SVG images.</p>
+
+   </dd>
+
+  </dl>
+
   <div w-nodev>
 
+  <p>The <dfn><code data-x="dom-embed-getSVGDocument">getSVGDocument()</code></dfn> method must run
+  the following steps:</p>
+
+  <ol>
+
+   <li><p>If the element has no <span>nested browsing context</span>, then return null and abort
+   these steps.</p></li>
+
+   <li><p>If the <span>active document</span> of the <span>nested browsing context</span> does not
+   have the <span data-x="same origin">same</span> <span>effective script origin</span> as the
+   <code>embed</code> element's <code>Document</code>, then return null and abort these
+   steps.</p></li>
+
+   <li><p>If the <span>nested browsing context</span>'s <span>active document</span> was created by
+   the <span data-x="navigate-xml">page load processing model for XML files</span> section because
+   <span>the sniffed type of the resource</span> in the <span>navigate</span> algorithm was
+   <code>image/svg+xml</code>, then return that <code>Document</code> object and abort these
+   steps.</p></li>
+
+   <li><p>Otherwise, return null.</p></li>
+
+  </ol>
+
   <p>The IDL attributes <dfn><code data-x="dom-embed-src">src</code></dfn> and <dfn><code data-x="dom-embed-type">type</code></dfn> each must <span>reflect</span> the respective
   content attributes of the same name.</p>
 
   </div>
 
+<!--TOPIC:HTML-->
+
   <div class="example">
 
    <p>Here's a way to embed a resource that requires a proprietary plugin, like Flash:</p>



More information about the Commit-Watchers mailing list