Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS Unused CSS Stages Media Queries Device-Specific Media Queries

Shouldn't 1 at pixel ratio of 2 be 4 pixels?

Since it's being doubled both vertically and horizontally, the 1x1 pixel becomes a 2x2 square, aka 4 pixels.

1 Answer

Hi Ian,

Think of the device pixel ratio as a linear measurement. One direction only.

1 css pixel equates to 2 horizontal physical pixels or 2 vertical physical pixels.

See if this older discussion helps you out: https://teamtreehouse.com/forum/device-pixel-density-of-2-means-4-device-pixels-per-logical-pixel