【发布时间】:2014-10-27 15:18:44
【问题描述】:
看起来 Firefox 无法理解我想从他那里得到什么。 Chrome 非常了解我。但是当我将 (font-face:normal) 写入属性时,Firefox 拒绝理解想要“正常”字体。它使我的块“ligter”就像父块中的字体一样。为什么!?!? !?
@font-face{
font-family:Myriad;
src:url('../fonts/MyriadPro-R.ttf');
font-weight:normal;
font-style:normal;
}
@font-face{
font-family:Myriad;
src:url('../fonts/MyriadPro-B.ttf');
font-weight:bold;
font-style:normal;
}
@font-face{
font-family:Myriad;
src:url('../fonts/MyriadPro-L.ttf');
font-weight:lighter;
font-style:normal;
}
【问题讨论】:
-
为什么不使用免费的网络字体?加载许可 Myriad Pro 字体看起来不正确。根据 CSS 规范,
normal= 400。加载的字体是否有字体粗细 400 ?此外,在font-family中仅使用一种字体是一种非常糟糕的做法(不提供回退);添加至少 1 种后备字体,尤其是您使用自定义字体。