Re: [csswg-drafts] [css-values] Ability to address actual physical size (#614)

> We currently have a use-case for this. Our web app is used in a laboratory working environment. One of our workflows requires pipetting small amounts of a reagent onto a glass slide. The exact placement is paramount, so we show a template that indicates the points where the reagent has to be pipetted upon. In order for that to work, we need to have the template on the screen match the physical slide 1:1.

I don't see how this use case would be helped by introducing units that are guaranteed to be the same size as physical measurements **regardless of the device it's being run on**. You show the template on a particular screen, and for that screen, it needs to be right. You don't need the same website to have the exact same physical measurements if it is displayed on a watch, a phone, a wall projector, or virtual reality goggles, all while ensuring that the `px` unit does scale according to those environment.. That's what a physical unit independent of the device would give you: a responsive `px` unit that changes based on viewing distance AND physical measurements that stay the same in any environments.

CSS already has a cm unit (and other physical units), and it is ratio is fixed with the px unit. But User Agents have leeway in terms of what they [anchor](https://www.w3.org/TR/css-values-3/#anchor-unit) these units to. Given your use case, your setup should anchor the absolute length units on the physical ones, and let everything fall from there. And if it is displayed on a watch the template will be scaled down, on a wall projector it will be scaled up, and that's ok: you're not doing your lab work on a watch or on the wall.



-- 
GitHub Notification of comment by frivoal
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/614#issuecomment-610119739 using your GitHub account

Received on Tuesday, 7 April 2020 01:20:06 UTC