今天的需求是做一個畫布框;需求需要用到12px的字體;從12px改到8px;然而字體並無變化;以下方案已解決此問題:
HTML部分:
<div class="act_text">
<ul>
<li>
<p>選擇圖片</p>
<p>水平反轉</p>
<p>上下反轉</p>
<p>左反轉</p>
<p>右反轉</p>
</li>
</ul>
</div>
css部分:
.act_text ul {
float: left;
height: 25px;
width: 100%;
/* 添加 */
-webkit-transform-origin-x: 0;
-webkit-transform: scale(0.90);
}
.act_text p {
float: left;
margin: 0 5px 10px;
/* 這裏可以調到最小的1px */
font-size: 1px;
font-weight: 700;
}
兼容I7↑版本。