刚用了chrome浏览器发现无法显示12px以下的字体,于是去stackoverflow上查了下。发现以前可以用
-webkit-text-size-adjust来改变,但是
Chrome 27之后不能用了,经过查找偶发现了这个
效果不错,由于
<!DOCTYPE html>
<html>
<head>
<title>Putting it all together</title>
</head>
<body>
<p style="font-size:10px;transform: scale(0.833);margin-left:-38">A truly spectacular paragraph!</p>
<p style="font-size:10px">A truly spectacular paragraph!</p>
</body>
</html>
transform: scale(0.833)
是整体缩放所以得设置margin-left(我这是10px的 0.833=10/12)