| |
I'm using Jaijaz's Bootstrap branch with CSSTidy so the rules are fine.
Firefox appears to be picky about using relative paths and Jojo won't serve the font files out of the CSS directory.
I've also tried serving a fonts.css and the font files from external/fonts and Firefox still doesn't show them. Can anyone help?
I tend to serve the font files out of the files directory like we used to for flash stuff as it doesn't get touched by any preprocessing.
CCSTidy will strip multiple @font-face rules as it see them as duplicates. If more than one needed then I tend to put them in the customhead file. Actually helps with font render speed too but at the expensive of images etc.
Hope that helps.
one was to do with the weird character they use to force the font-face rather than a local version (which I'm not sure I agree with in any case) but i think they fixed it in the later versions
the other is really stupid but consistently causes issues - remove the linebreaks between the various url links in the second src declaration so it's all on one line eg:
@font-face {
font-family: 'TeXGyreAdventorBold';
src: url('../external/texgyreadventor-bold-webfont.eot');
src: local('�?�¢�??�?�º'), url('../external/texgyreadventor-bold-webfont.woff') format('woff'), url('../external/texgyreadventor-bold-webfont.ttf') format('truetype'), url('../external/texgyreadventor-bold-webfont.svg#webfontTc3iYEdw') format('svg');
font-weight: bold;
font-style: normal;
}
I've also found that, contrary to the fontsquirrel recommendation, if you have a style that you are declaring bold that uses a bold fontface family member, and the fontface style is not also set to font-weight: bold; it will double-bold it in some browsers (can't remember if its webkit or ff)
h2 {
font-family: 'TeXGyreAdventorBold', Arial, Helvetica, sans-serif;
font-weight: bold;
}
font-family:'HandOfSeanRegular';
src:url(handsean-webfont.eot);
src:url(handsean-webfont.eot?#iefix) format(embedded-opentype),
url(handsean-webfont.woff) format(woff),
url(handsean-webfont.ttf) format(truetype),
url(handsean-webfont.svg#HandOfSeanRegular) format("svg");
font-weight:normal;
font-style:normal;
}
This was served as /external/fonts.css with the fonts in the same directory since I had issues tried to serve from /fonts/ and wanted to rule out having "../" in the path from the main css file to externals.
I just tried with Tom's code and still haven't got it running in FF. Next step will be to try throwing it in customhead or try a different font.
@font-face{
font-family:'HandOfSeanRegular';
src:url(../files/handsean-webfont.eot);
src:url(../files/handsean-webfont.eot?#iefix) format(embedded-opentype),
url(../files/handsean-webfont.woff) format(woff),
url(../files/handsean-webfont.ttf) format(truetype),
url(../files/handsean-webfont.svg#HandOfSeanRegular) format("svg");
font-weight:normal;
font-style:normal;
}
Firefox is quite aggressive with caching font files - you don't have an old, bad version lurking somewhere ? Or locally?
Do you run Charles? - is the request going through and not returning the file, or is the request not being made?
Thanks for the help.
| Back to Forum Index : Back to Themes Support |
|
