Skip to content
Browse files

[] (0) <link rel='icon' sizes=''>

git-svn-id: http://svn.whatwg.org/webapps@1558 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information...
1 parent 0834f67 commit e07d081bbf882221edcddb1208fad964f9c8557e @Hixie Hixie committed
Showing with 160 additions and 4 deletions.
  1. +82 −2 index
  2. +78 −2 source
View
84 index
@@ -7467,6 +7467,8 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
<dd><code title=attr-link-type><a href="#type">type</a></code>
+ <dd><code title=attr-link-sizes><a href="#sizes0">sizes</a></code>
+
<dd>Also, the <code title=attr-link-title><a
href="#title2">title</a></code> attribute has special semantics on this
element.
@@ -7483,6 +7485,7 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
attribute DOMString <a href="#media1" title=dom-link-media>media</a>;
attribute DOMString <a href="#hreflang0" title=dom-link-hreflang>hreflang</a>;
attribute DOMString <a href="#type0" title=dom-link-type>type</a>;
+ attribute DOMString <a href="#sizes" title=dom-link-sizes>sizes</a>;
};</pre>
<p>The <code>LinkStyle</code> interface must also be implemented by this
@@ -7670,6 +7673,14 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
elements in that a link without a title does not inherit the title of the
parent element: it merely has no title.
+ <p>The <code title=attr-link-sizes><a href="#sizes0">sizes</a></code>
+ attribute is used with the <code title=rel-icon><a
+ href="#icon3">icon</a></code> link type. The attribute must not be
+ specified on <code><a href="#link">link</a></code> elements that do not
+ have a <code title=attr-link-rel><a href="#rel">rel</a></code> attribute
+ that specifies the <code title=rel-icon><a href="#icon3">icon</a></code>
+ keyword.
+
<p>Some versions of HTTP defined a <code title="">Link:</code> header, to
be processed like a series of <code><a href="#link">link</a></code>
elements. When processing links, those must be taken into consideration as
@@ -7687,7 +7698,8 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
title=dom-link-rel><code>rel</code></dfn>, <dfn id=media1
title=dom-link-media><code>media</code></dfn>, <dfn id=hreflang0
title=dom-link-hreflang><code>hreflang</code></dfn>, and <dfn id=type0
- title=dom-link-type><code>type</code></dfn> each must <a
+ title=dom-link-type><code>type</code></dfn>, and <dfn id=sizes
+ title=dom-link-sizes><code>sizes</code></dfn> each must <a
href="#reflect">reflect</a> the respective content attributes of the same
name.
@@ -34700,13 +34712,81 @@ at the first element with the given ID must be treated as if it was cloned and r
<p>Icons could be auditory icons, visual icons, or other kinds of icons. If
multiple icons are provided, the user agent must select the most
appropriate icon according to the <code title=attr-link-media><a
- href="#media0">media</a></code> attribute.
+ href="#media0">media</a></code> and <code title=attr-link-sizes><a
+ href="#sizes0">sizes</a></code> attributes. If there are multiple equally
+ appropriate icons, user agents must use the first one declared in <a
+ href="#tree-order">tree order</a>.
<p>There is no default type for resources given by the <code
title=rel-icon><a href="#icon3">icon</a></code> keyword.</p>
<!-- XXX we don't define
the content-type sniffing for this keyword -->
+ <p>The <dfn id=sizes0 title=attr-link-sizes><code>sizes</code></dfn>
+ attribute gives the sizes of icons for visual media.
+
+ <p>If the specified, the attribute must have a value that is an <a
+ href="#unordered">unordered set of unique space-separated tokens</a>. The
+ values must all be either <code title=attr-link-sizes-any><a
+ href="#any-keyword">any</a></code> or a value that consists of two <a
+ href="#valid" title="valid non-negative integer">valid non-negative
+ integers</a> that do not have a leading U+0030 DIGIT ZERO (0) character
+ and that are separated by a single U+0078 LATIN SMALL LETTER X character.
+
+ <p>The keywords represent icon sizes.
+
+ <p>To parse and process the attribute's value, the user agent must first <a
+ href="#split" title="split a string on spaces">split the attribute's value
+ on spaces</a>, and must then parse each resulting keyword to determine
+ what it represents.
+
+ <p>The <dfn id=any-keyword title=attr-link-sizes-any><code>any</code>
+ keyword represents that the resource contains a scalable icon, e.g. as
+ provided by an SVG image.</dfn>
+
+ <p>Other keywords must be further parsed as follows to determine what they
+ represent:
+
+ <ul>
+ <li>
+ <p>If the keyword doesn't contain exactly one U+0078 LATIN SMALL LETTER X
+ character, then this keyword doesn't represent anything. Abort these
+ steps for that keyword.
+
+ <li>
+ <p>Let <var title="">width string</var> be the string before the "<code
+ title="">x</code>".
+
+ <li>
+ <p>Let <var title="">hight string</var> be the string after the "<code
+ title="">x</code>".
+
+ <li>
+ <p>If either <var title="">width string</var> or <var title="">height
+ string</var> start with a U+0030 DIGIT ZERO (0) character or contain any
+ characters other than characters in the range U+0030 DIGIT ZERO (0) to
+ U+0039 DIGIT NINE (9), then this keyword doesn't represent anything.
+ Abort these steps for that keyword.
+
+ <li>
+ <p>Apply the <a href="#rules">rules for parsing non-negative integers</a>
+ to <var title="">width string</var> to obtain <var title="">width</var>.
+
+ <li>
+ <p>Apply the <a href="#rules">rules for parsing non-negative integers</a>
+ to <var title="">height string</var> to obtain <var
+ title="">height</var>.
+
+ <li>
+ <p>The keyword represents that the resource contains a bitmap icon with a
+ width of <var title="">width</var> device pixels and a height of <var
+ title="">height</var> device pixels.
+ </ul>
+
+ <p>The keywords specified on the <code title=attr-link-sizes><a
+ href="#sizes0">sizes</a></code> attribute must not represent icon sizes
+ that are not actually available in the linked resource.
+
<h5 id=link-type8><span class=secno>4.12.3.10. </span>Link type "<dfn
id=license title=rel-license><code>license</code></dfn>"</h5>
View
80 source
@@ -5899,6 +5899,7 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
<dd><code title="attr-link-media">media</code></dd>
<dd><code title="attr-link-hreflang">hreflang</code></dd>
<dd><code title="attr-link-type">type</code></dd>
+ <dd><code title="attr-link-sizes">sizes</code></dd>
<dd>Also, the <code title="attr-link-title">title</code> attribute has special semantics on this element.</dd>
<dt>DOM interface:</dt>
<dd>
@@ -5910,6 +5911,7 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
attribute DOMString <span title="dom-link-media">media</span>;
attribute DOMString <span title="dom-link-hreflang">hreflang</span>;
attribute DOMString <span title="dom-link-type">type</span>;
+ attribute DOMString <span title="dom-link-sizes">sizes</span>;
};</pre>
<p>The <code>LinkStyle</code> interface must also be implemented
by this element, the <span>styling processing model</span> defines
@@ -6102,6 +6104,12 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
elements in that a link without a title does not inherit the title
of the parent element: it merely has no title.</p>
+ <p>The <code title="attr-link-sizes">sizes</code> attribute is used
+ with the <code title="rel-icon">icon</code> link type. The attribute
+ must not be specified on <code>link</code> elements that do not have
+ a <code title="attr-link-rel">rel</code> attribute that specifies
+ the <code title="rel-icon">icon</code> keyword.</p>
+
<p>Some versions of HTTP defined a <code title="">Link:</code>
header, to be processed like a series of <code>link</code> elements.
When processing links, those must be taken into consideration as
@@ -6120,7 +6128,8 @@ onActivate, onBeforeDeactivate, onDeactivate, document.hasFocus):
title="dom-link-rel"><code>rel</code></dfn>, <dfn
title="dom-link-media"><code>media</code></dfn>, <dfn
title="dom-link-hreflang"><code>hreflang</code></dfn>, and <dfn
- title="dom-link-type"><code>type</code></dfn> each must
+ title="dom-link-type"><code>type</code></dfn>, and <dfn
+ title="dom-link-sizes"><code>sizes</code></dfn> each must
<span>reflect</span> the respective content attributes of the same
name.</p>
@@ -32437,12 +32446,79 @@ at the first element with the given ID must be treated as if it was cloned and r
<p>Icons could be auditory icons, visual icons, or other kinds of
icons. If multiple icons are provided, the user agent must select
the most appropriate icon according to the <code
- title="attr-link-media">media</code> attribute.</p>
+ title="attr-link-media">media</code> and <code
+ title="attr-link-sizes">sizes</code> attributes. If there are
+ multiple equally appropriate icons, user agents must use the first
+ one declared in <span>tree order</span>.</p>
<p>There is no default type for resources given by the <code
title="rel-icon">icon</code> keyword.</p> <!-- XXX we don't define
the content-type sniffing for this keyword -->
+ <p>The <dfn title="attr-link-sizes"><code>sizes</code></dfn>
+ attribute gives the sizes of icons for visual media.</p>
+
+ <p>If the specified, the attribute must have a value that is an
+ <span>unordered set of unique space-separated tokens</span>. The
+ values must all be either <code
+ title="attr-link-sizes-any">any</code> or a value that consists of
+ two <span title="valid non-negative integer">valid non-negative
+ integers</span> that do not have a leading U+0030 DIGIT ZERO (0)
+ character and that are separated by a single U+0078 LATIN SMALL
+ LETTER X character.</p>
+
+ <p>The keywords represent icon sizes.</p>
+
+ <p>To parse and process the attribute's value, the user agent must
+ first <span title="split a string on spaces">split the attribute's
+ value on spaces</span>, and must then parse each resulting keyword
+ to determine what it represents.</p>
+
+ <p>The <dfn title="attr-link-sizes-any"><code>any</code> keyword
+ represents that the resource contains a scalable icon, e.g. as
+ provided by an SVG image.</p>
+
+ <p>Other keywords must be further parsed as follows to determine
+ what they represent:</p>
+
+ <ul>
+
+ <li><p>If the keyword doesn't contain exactly one U+0078 LATIN
+ SMALL LETTER X character, then this keyword doesn't represent
+ anything. Abort these steps for that keyword.</p></li>
+
+ <li><p>Let <var title="">width string</var> be the string before
+ the "<code title="">x</code>".</p></li>
+
+ <li><p>Let <var title="">hight string</var> be the string after the
+ "<code title="">x</code>".</p></li>
+
+ <li><p>If either <var title="">width string</var> or <var
+ title="">height string</var> start with a U+0030 DIGIT ZERO (0)
+ character or contain any characters other than characters in the
+ range U+0030 DIGIT ZERO (0) to U+0039 DIGIT NINE (9), then this
+ keyword doesn't represent anything. Abort these steps for that
+ keyword.</p></li>
+
+ <li><p>Apply the <span>rules for parsing non-negative
+ integers</span> to <var title="">width string</var> to obtain <var
+ title="">width</var>.</p></li>
+
+ <li><p>Apply the <span>rules for parsing non-negative
+ integers</span> to <var title="">height string</var> to obtain <var
+ title="">height</var>.</p></li>
+
+ <li><p>The keyword represents that the resource contains a bitmap
+ icon with a width of <var title="">width</var> device pixels and a
+ height of <var title="">height</var> device pixels.</p></li>
+
+ </ul>
+
+ <p>The keywords specified on the <code
+ title="attr-link-sizes">sizes</code> attribute must not represent
+ icon sizes that are not actually available in the linked
+ resource.</p>
+
<h5>Link type "<dfn title="rel-license"><code>license</code></dfn>"</h5>

0 comments on commit e07d081

Please sign in to comment.
Something went wrong with that request. Please try again.