【发布时间】:2012-08-25 19:40:27
【问题描述】:
我上传了一个我们公司外包的登录页面,Firefox 不渲染Lato 字体,而是退回到更底层的东西。
我们从 fonts.googleapis.com 获得了以下样式表。
@font-face {
font-family: 'Lato';
font-style: normal;
font-weight: 700;
src: local('Lato Bold'), local('Lato-Bold'), url(https://themes.googleusercontent.com/static/fonts/lato/v6/wkfQbvfT_02e2IWO3yYueQ.woff) format('woff');
}
@font-face {
font-family: 'Lato';
font-style: normal;
font-weight: 100;
src: local('Lato Hairline'), local('Lato-Hairline'), url(https://themes.googleusercontent.com/static/fonts/lato/v6/boeCNmOCCh-EWFLSfVffDg.woff) format('woff');
}
@font-face {
font-family: 'Lato';
font-style: normal;
font-weight: 300;
src: local('Lato Light'), local('Lato-Light'), url(https://themes.googleusercontent.com/static/fonts/lato/v6/KT3KS9Aol4WfR6Vas8kNcg.woff) format('woff');
}
@font-face {
font-family: 'Lato';
font-style: normal;
font-weight: 400;
src: local('Lato Regular'), local('Lato-Regular'), url(https://themes.googleusercontent.com/static/fonts/lato/v6/9k-RPmcnxYEPm8CNFsH2gg.woff) format('woff');
}
在 IE、Chrome、Opera 和 Safari 中没有问题。 Firefox 是否有什么特别之处无法显示字体?
【问题讨论】:
-
你用的是什么版本的FF?在最新版本上运行良好:jsfiddle.net/charlescarver/znKfg/2
-
在 FF 14.0.1 中也为我工作:jsfiddle.net/e6JWm/1
-
我已经在 Vista 中尝试了 15 次,在 Ubuntu 中尝试了 14 次。
-
我已关注您的链接,但字体未在我的浏览器中呈现。
-
也为我工作! Windows 7 中的 FF 15!
标签: css firefox font-face noscript google-font-api