I love the module but think it could use some android support.

according to this site: http://www.brianhadaway.com/font-face-declarations-on-android-devices/ it can be done with the updated syntax.

Is this something that you would be looking to update or would it conflict with your bullet proof implementation?

Comments

sreynen’s picture

Title: Andriod support » Andriod support for local fonts
Version: 6.x-2.10 » 7.x-2.x-dev

We're only generating the @font-face syntax for local fonts, so that's the most we could change. The hosted font providers do their own thing there. I didn't realize the current syntax doesn't work on Android. I'll have to read more on alternative syntaxes to make it work on Android without breaking anything else. If we do update the syntax, we'll do it in 7.x-2.x first, then backport it.

btmash’s picture

I don't have font-your-face enabled on my site so I haven't checked exactly what the syntax looks like. But the syntax we use on our sites for custom fonts that I was able to get working (seems to work on the various browsers/devices) was the following:

@font-face {
    font-family: 'MyLocalFont';
    src: url('mylocalfont-webfont.eot');
    src: url('mylocalfont-webfont.eot?iefix') format('eot'),
         url('mylocalfont-webfont.woff') format('woff'),
         url('mylocalfont-webfont.ttf') format('truetype'),
         url('mylocalfont-webfont.svg#webfontOo3dhpqg') format('svg');
    font-weight: normal;
    font-style: normal;
}

What I see fontsquirrel now using is the following:

@font-face {
    font-family: 'UndercoverRegular';
    src: url('UNDERCOV-webfont.eot');
    src: url('UNDERCOV-webfont.eot?#iefix') format('embedded-opentype'),
         url('UNDERCOV-webfont.woff') format('woff'),
         url('UNDERCOV-webfont.ttf') format('truetype'),
         url('UNDERCOV-webfont.svg#UndercoverRegular') format('svg');
    font-weight: normal;
    font-style: normal;

}

So the only different seems to be the format for the iefix. I'll try and test things out on my end to see how well it all works.

sreynen’s picture

Status: Active » Needs review

I committed the syntax BTMash suggested, which is also what Fontspring recommends. Can anyone confirm this works on Android now?

florisg’s picture

Confirmed patch from: http://drupalcode.org/project/fontyourface.git/blobdiff/c9afc518b20a7209...
works against @font-your-face 7.x-2.2

sreynen’s picture

Status: Needs review » Reviewed & tested by the community

Sounds like this has been reviewed.

sreynen’s picture

Status: Reviewed & tested by the community » Fixed

This seems to be fixed. If anyone is still having this problem with latest dev or the 7.x-2.3 release I'm making right now, please re-open this.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.