- From: Eric Shepherd <eshepherd@mozilla.com>
- Date: Tue, 14 Oct 2008 15:50:45 -0400
- To: www-style@w3.org
While writing documentation for media queries support coming in Firefox 3.1, it was pointed out to me by a reviewer that there's a potential problem with the specification when it comes to using min- and max-prefixes to create media queries in which the two ranges need to abut one another. For example: <link rel=”stylesheet” media=”(max-device-aspect-ratio: 10/10)” href=”portrait.css”> <link rel=”stylesheet” media=”(min-device-aspect-ratio: 11/10)” href=”landscape.css”> In this case, a sheet of paper with a printable area of 2500/2400 pixels would fall in between these two and neither style sheet would load. There's no way to specify these ratios such that there aren't cases where neither style sheet might be used. Someone might try to deal with this problem in this manner: <link rel=”stylesheet” media=”(max-device-aspect-ratio: 1/1)” href=”portrait.css”> <link rel=”stylesheet” media=”(min-device-aspect-ratio: 1/1)” href=”landscape.css”> But now you have the problem of what to do if the device has a square aspect ratio (1/1). I presume the first sheet should be used; however, this might not be the intended effect. Eric Shepherd Developer Documentation Lead Mozilla Corporation Blog: http://www.bitstampede.com
Received on Tuesday, 14 October 2008 19:51:27 UTC