Font Anti-Aliasing Disparities on Windows and Mac: @font-face Resolution
When using @font-face kits from Font Squirrel, web developers often encounter discrepancies in the resulting font rendering between Windows and Mac systems. Windows browsers display the font with thicker and rougher anti-aliasing compared to Mac browsers.
To rectify this issue, it has been discovered that Chrome specifically has a preference for the order of font file formats included in the @font-face declaration. By moving the SVG font file format to the top of the list, allowing Chrome to prioritize it, the anti-aliasing issue can be resolved.
Revised @font-face Declaration:
@font-face { font-family: 'HLC'; src: url('/_styles/hlc/hl-webfont.svg#HLC') format('svg'), url('/_styles/hlc/hl-webfont.eot') format('embedded-opentype'), url('/_styles/hlc/hl-webfont.woff') format('woff'), url('/_styles/hlc/hl-webfont.ttf') format('truetype'); font-weight: normal; font-style: normal; }
This revised declaration ensures that Chrome will prioritize the SVG font file, resulting in consistent and high-quality anti-aliased font rendering on both Windows and Mac platforms.
The above is the detailed content of Why Does Font Anti-Aliasing Differ Between Windows and Mac, and How Can I Fix it Using @font-face?. For more information, please follow other related articles on the PHP Chinese website!