Roboto Condensed Font not rendering properly in mozilla firefox

别来无恙 提交于 2019-12-13 03:44:07

问题


I am using RobotoCondensed downloaded from google Web Fonts. I am using the font from my server. I have created the css like below.

@font-face {
    font-family: 'Roboto Condensed';
    src: url('../fonts/RobotoCondensed-Light.eot');
    src: url('../fonts/RobotoCondensed-Light.eot?#iefix') format('embedded-opentype'), 
         url('../fonts/RobotoCondensed-Light.woff') format('woff'), 
         url('../fonts/RobotoCondensed-Light.ttf')  format('truetype'), 
         url('../fonts/RobotoCondensed-Light.svg#svgFontName') format('svg'); 
    }

All the font types specified are present in the folder that I have specified in the url.

I am using the font family like this

font-family: 'Roboto Condensed', sans-serif;

The things are going smooth with respect to IE9 and Chrome. But when it comes to Mozilla Firefox it is not so.

Is there any solution for this?


回答1:


I'm using the one off the Google Fonts Api and it works in Firefox:

@font-face {
  font-family: 'Roboto Condensed';
  font-style: normal;
  font-weight: 400;
  src: local('Roboto Condensed Regular'), local('RobotoCondensed-Regular'), url(http://themes.googleusercontent.com/static/fonts/robotocondensed/v7/Zd2E9abXLFGSr9G3YK2MsNxB8OB85xaNTJvVSB9YUjQ.woff) format('woff');
}

Maybe try specifying style and weight.




回答2:


just remove : font-weight: 300; from woff



来源:https://stackoverflow.com/questions/16911367/roboto-condensed-font-not-rendering-properly-in-mozilla-firefox

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!