Working with @font-face

You have downloaded the Web font kit and have tested the demo.html file in a browser. Now it’s time to look under the hood and see how this works. Let’s look at the code for stylesheet.css Image.

Image This is the @font-face rule that Font Squirrel provides in the kit. You may notice that it uses single quotes instead of the double quotes shown in CSS examples throughout the book. Single quotes and double quotes work the same way in CSS, so use whichever method you prefer.

@font-face {font-family: 'LeagueGothicRegular';src: url('League_Gothic-webfont.eot'); ...

Get HTML5 and CSS3: Visual QuickStart Guide, Seventh Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.