[whatwg] <link rel=icon width="" height="">

Lachlan Hunt wrote:
> Martin Atkins wrote:
>> Lachlan Hunt wrote:
>>> For color, you are reinventing Media Queries. For compression, you 
>>> are basically reinventing q values for MIME types.
>>>
>>> <link type="image/png;q=1.0" media="all and (min-color:8)">
>>> <link type="image/jpeg;q=0.8" media="all and (min-color:8)">
>>
>> Could this be said about size as well?
>>
>> <link type="image/png"
>>       media="all and (max-width:16px and max-height:16px)">
> 
> No, because the media queries are related to the actual tech specs of 
> the device, not the image.  I'm fairly sure there are no 16x16px screens 
> in use, at least not for the web.  To get appropriate behaviour for what 
> you're suggesting here would require redefining and special casing media 
> queries.
> 
> 

When I shrink my browser window down so that its viewport is 16x16px 
(assuming that it'd let me do such a thing) it's quite happy to apply a 
stylesheet with the above media query. It seems, therefore, that the 
"width" and "height" constraints relate to the rendering viewport and 
not to the device.

The only "leap of faith" I see here is that when rel="stylesheet" we're 
talking about the width of the source document's viewport -- because 
stylesheets don't have a viewport of their own -- but in the icon case 
we'd be describing the *icon* viewport i.e. the box into which the icon 
will be rendered.

device-width and device-height seem to be more like what you're 
describing, though I'm not sure why you'd ever want to use these since 
browsers rarely inhabit the entire physical display even on mobile devices.

Received on Thursday, 1 May 2008 00:02:58 UTC