Answer the question
In order to leave comments, you need to log in
Is it possible to set an absolute size relative to visual perception to an element / text?
For web development of front end interfaces.
It would be great to set the size of the text or element in strict accordance with reality, despite the different pixel densities of the screens.
Of course, this would be logical only for mobile devices and desktop monitors, but for TVs that also view the web, this would not be applicable because there the pixel density is very low with such a large diagonal.
But still, mb is a way to indicate the size at least approximately similar to the real size.
Isn't there a correlation between physical screen size and pixel density?
Apple seems to have done something similar before ... but now it's confusion again.
Answer the question
In order to leave comments, you need to log in
Again, for the billion-first time, text size has nothing to do with pixel density .
You can, for this there are absolute units in CSS ( W3C , MDN ):
mm (millimeter), cm (centimeter), in (inch), etc.
In most cases, the accuracy of calculating these dimensions is enough, but still they warn on SO :
Result still depends on the correct reading of the monitor size by the operating system.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question