-1

我将使用@font-face。所以我将corbel字体复制到我的目录中,它显示了4种字体CORBEL_0.TTF , CORBELB_0.TTF , CORBELI_0.TTF , CORBELZ_0.TTF,接下来我将Kozuka Gothic Pro字体复制到我的目录中,它显示了6种字体KozGoPro-Bold.otf , KozGoPro-ExtraLight.otf , KozGoPro-Heavy.otf , KozGoPro-Light.otf , KozGoPro-Medium.otf , KozGoPro-Regular.otf

如何使用@font-face 规则编写 src?如示例 url("../../css/fonts/League_Gothic.eot") format('eot'); 格式eot,是字体的扩展名吗?任何人都可以给我@font-face 中完整语法的想法。

4

2 回答 2

0
@font-face
{
font-family: corbel;
src: url('/fonts/corbel.ttf'),
 url('/fonts/corbel.eot'); 
} 

@font-face
{
font-family: Kozuka;
src: url('/fonts/Kozuka.ttf'),
 url('/fonts/Kozuka.eot'); 
} 
于 2013-07-08T07:27:05.410 回答
0

像这样:

@font-face {
    font-family: 'Kozuka Gothic Pro';
    src: url("../../css/fonts/Kozuka Gothic Pro.otf") format('truetype');
    src: local("☺"),
    url("../../css/fonts/KozGoPro-Bold.otf"),
    url("../../css/fonts/KozGoPro-ExtraLight.otf") format('truetype'), 
    url("../../css/fonts/KozGoPro-Heavy.otf") format('truetype'), 
    url("../../css/fonts/KozGoPro-Light.otf") format('truetype');
    url("../../css/fonts/KozGoPro-Medium.otf") format('truetype')
    url("../../css/fonts/KozGoPro-Regular.otf") format('truetype');
}
于 2013-07-08T07:30:42.343 回答