开发者

Deciding on a font: browser support for Cambria and other fonts?

开发者 https://www.devze.com 2023-03-25 09:33 出处:网络
Our web designer su开发者_高级运维ggested using Cambria as a font. In looking at various font references online, we couldn\'t find authoritative sources that listed recent (post 2010) browser support

Our web designer su开发者_高级运维ggested using Cambria as a font. In looking at various font references online, we couldn't find authoritative sources that listed recent (post 2010) browser support for various fonts.

Which sources do you use to determine how supported a particular font is? I'm guessing there are reports for fonts like there are for browsers, but we haven't found anything reliable yet.


I think you don't need to worry too much about native browser support for fonts. Instead you should consider two things:

  1. Using @font-face
  2. Using a good font stack

Combine the two and you should be safe, no matter what.

For @font-face, you can generate the font and make it cross-browser compatible.

  1. Start by licensing the font from here ( http://new.myfonts.com/search/cambria/ ) or somewhere else.

  2. Then generate the @font-face code with Font Squirrel ( http://www.fontsquirrel.com/fontface/generator ) or another service. The result will be cross browser compatible in nearly all cases.

  3. Finally, add the font to a font stack so that there is a fall back in case something happens with your custom Cambria font. Something like this for whichever rule you are working with: font-family: Cambria, Georgia, Palatino, Times New Roman, serif;

Of course, you could also choose a similar free font through Font Squirrel or use Google's Web Fonts.

More good info here: http://sixrevisions.com/css/font-face-guide/


You won't find Cambria and the other fonts in its family natively installed on computers running anything but Windows Vista and newer, and you'll only have luck on other systems if they have Office 2007/2008 and newer installed.

As long as the font is present on a user's computer, any browser should be able to handle it, even without the need for @font-face embedding. The idea of font embedding is to get a browser to recognize and use a font that isn't installed on a user's system, rather than getting the browser to understand and render the font.


You're not going to find something that works on everything. Try Cambria, Georgia, serif; Georgia's a reasonably close substitute that's very widespread, and the serif default will work anywhere.


Discussion here: http://en.wikipedia.org/wiki/Cambria_%28typeface%29

The browser doesn't have much to say as to the fonts it supports; they are dictated by the fonts present in the underlying OS.


It's hard to find support references for particular fonts. However, @font-face is widely supported and regardless, a good font stack with fail-safe fonts is a must-have.

0

精彩评论

暂无评论...
验证码 换一张
取 消