Is 1 CSS point equal to 75% to a CSS Pixel? [duplicate]

ⅰ亾dé卋堺 提交于 2019-12-25 16:57:37

问题


I'm trying to understand the how CSS pixels relates to CSS points nowadays and what I've read is that one css point is a 3/4 pixel. Is that correct? And I can ignore the old idea that 1pt would be 1/72 of 1in because of difference in resolution and physical monitor sizes.

If I want to convert css points to pixels a formula could look like this then? Xpt/75*100 = Ypx

And if want to convert pixels to points the formula could look like this: Xpx -25% = Ypt


回答1:


It depends on your screen resolution and how many pixels per inch you have (often referred to as dpi instead of ppi) - as you say 1pt is 1/72 of an inch.

As most monitors are 96dpi that means that 1pt = 72 / 96 = 0.75 pixels



来源:https://stackoverflow.com/questions/43754979/is-1-css-point-equal-to-75-to-a-css-pixel

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!