Describes the resolution of the output device—that is, the density of the pixels.
Possible values
- Value: <resolution>
- Applies to: bitmap media types
- Accepts min/max prefixes: yes
Remarks
The resolution of the device can be described in either dots per inch (dpi) or dots per centimeter (dpcm).
When querying devices with non-square (rectangular) pixels:
- Specifying min-resolution causes the least-dense dimension to be compared to the given value
- Specifying max-resolution causes the most-dense dimension to be compared to the given value
- Specifying resolution (without a "min-" or "max-" prefix) never matches a device with non-square pixels
Examples
The following declaration indicates that a style sheet is usable on devices with resolution greater than 300 dpi.
@media print and (min-resolution: 300dpi) {
...
}
The following declaration indicates that a style sheet is usable on devices with resolution greater than 118 dots per centimeter (dpcm).
@media print and (min-resolution: 118dpcm) {
...
}
Build date: 11/29/2012