@font面临不工作在Android [英] @font face not working on Android

查看:122
本文介绍了@font面临不工作在Android的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用@font脸下面的CSS。它的工作原理我的桌面上,我已经测试了IOS设备上。但它没有在Android:

I am using the following CSS for @font face. It works on my desktop and the IOS devices that I have tested. But it fails on Android:

@font-face {
    font-family: 'ReformaGroteskMedium';
    src: url('/css/fonts/reforma_grotesk/26890C_0_0.eot');
    src: url('/css/fonts/reforma_grotesk/26890C_0_0.eot?#iefix') format('embedded-opentype'),
         url('/css/fonts/reforma_grotesk/26890C_0_0.woff') format('woff'),
         url('/css/fonts/reforma_grotesk/26890C_0_0.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

我注意到,从 http://www.fontsquirrel.com/ 产生的字体(这工作)在完全相同的方式被包埋除非他们也有以下行:

I noticed that the fonts generated from http://www.fontsquirrel.com/ (which work) are embeded in exactly the same way except they also have the following line:

url('SourceSansPro-ExtraLightIt-webfont.svg#SourceSansProExtraLightItalic') format('svg');

这是为什么我的版本不工作,不只是Android的支持SVG?

Is this why my version isn't working, does Android only support SVG?

我使用的Andr​​oid版本是4.0.1在华硕平板。它没有一个较新的Andr​​oid手机上正常工作。

The version of Android I am using is 4.0.1 on a Asus tablet. It did work fine on a newer Android phone.

推荐答案

您可能会面临这个Android的bug:

You might be facing this Android bug:

HTTPS://$c$c.google。 COM / p /安卓/问题/细节?ID = 73945

据他们说这是固定在Android 4.4,但不是在previous版本:(

According to them it is fixed on Android 4.4 but not on previous versions :(

这篇关于@font面临不工作在Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆