CSS字体大小.5增量 [英] CSS Font Size .5 Increments

查看:275
本文介绍了CSS字体大小.5增量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在CSS中,您允许使用.5增量,即

In CSS are you allowed to use .5 increments i.e

font-size: 8.5pt;

无法看到font-size:8pt和font-size之间的差异:8.5pt


Can't see the difference between font-size: 8pt and font-size: 8.5pt

推荐答案

点值只适用于打印CSS。

Point values are really only for print CSS.


点是用于现实生活墨水纸上的
排版的测量单位。 72pts =一英寸。一英寸=一个现实生活的英寸
像一个尺子。

A point is a unit of measurement used for real-life ink-on-paper typography. 72pts = one inch. One inch = one real-life inch like-on-a-ruler. Not an inch on a screen, which is totally arbitrary based on resolution.

资料来源: http://css-tricks.com/css-font-size/

W3C提示页面建议避免屏幕:

The W3C Tips page suggest avoiding them for screen:


所谓的绝对单位(cm,mm,in,pt和pc )的意思是在
CSS相同的其他地方。在任何这些中表示的长度将出现
正好那个大小(在硬件和
软件的精度内)。他们不推荐在屏幕上使用,因为屏幕
的大小差别很大。一个大屏幕可能是60厘米(24英寸),一个小,便携式
屏幕也许只有8厘米。

The so-called absolute units (cm, mm, in, pt and pc) mean the same in CSS as everywhere else. A length expressed in any of these will appear as exactly that size (within the precision of the hardware and software). They are not recommended for use on screen, because screen sizes vary so much. A big screen may be 60cm (24in), a small, portable screen is maybe only 8cm. And you don't look at them from the same distance.

资料来源:http://www.w3.org/Style/Examples/007/units.en.html

这篇关于CSS字体大小.5增量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆