使用下载的字体离线 [英] Using downloaded font offline
本文介绍了使用下载的字体离线的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我刚刚下载了一个谷歌字体。我想在页面的特定部分使用它。
.page-header {
font-family:'我想我是以不正确的方式使用字体的。 Calligraffitti',草书;
src:url('../ fonts / Calligraffitti / Calligraffitti-Regular.ttf');
$ b 如果这不正确,你能告诉我使用字体的正确方法这是不是安装在系统上?
解决方案
添加此在您的CSS文档的顶部。
@ font-face {
font-family:Calli;
src:url('../ fonts / Calligraffitti / Calligraffitti-Regular.ttf');
$ / code>
您可以像这样使用它:
.page-header {
font-family:Calli;
}
I have just downloaded a google-font. I want to use it in a specific section of the page. I think I am using the font in an incorrect manner.
.page-header {
font-family: 'Calligraffitti', cursive;
src : url('../fonts/Calligraffitti/Calligraffitti-Regular.ttf');
}
If this is incorrect, could you tell me the correct way of using a font that is not installed on a system?
解决方案 Add this at the top of your CSS document.
@font-face {
font-family: Calli;
src: url('../fonts/Calligraffitti/Calligraffitti-Regular.ttf');
}
You can then use it like this:
.page-header {
font-family: Calli;
}
这篇关于使用下载的字体离线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文