html - 如何定义 CSS 字体?

标签 html css

我找到了字体定义并想知道:

  1. local定义了什么?

  2. font-weight 和 font-style 有什么区别?

CSS

 @font-face {
font-family: 'FontinSans';
src: local('...'), url('fontin_sans_regular.woff') format('woff');
font-weight: normal;
font-style: 400;
}

最佳答案

这是您的解决方案:

  1. local() 将从您的计算机获取字体。意味着您的机器中已经存在的任何字体都将优先使用它。

    请阅读this更清楚地了解字体

2.font-weight 用于显示字体的锐度,如lighter...light...normal..bold..bolder font-style 用于italic..normal..oblique

关于html - 如何定义 CSS 字体?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19952759/

相关文章:

html - CSS 定位问题仅在 Safari 中

javascript - 需要一次选择一张图片

php - Bootstrap 列根据移动 View 上的标题进行总结

html - Bootstrap 移动菜单 100%

html - Twitter Bootstrap 旧版 : Uniform height on spans

jquery - 从窗口获取位置

javascript - 为什么自定义验证消息导致我的 HTML 表单元素保持无效?

css - 旋转 Angular - V 形 - 单击

ios, webkit-overflow-scrolling : touch recognition on scrolling list is broken

css - 跨越父按钮的 100% 高度