【发布时间】:2013-01-09 17:56:29
【问题描述】:
如何添加小型大写字体作为变体?
我正在使用 Jos Buivenga 的 Fontin,它的小型大写字母变体是一种单独的字体,而不是一种 OpenType 风格的功能。这个 CSS sn-p 正确定义了该系列中的常规、粗体和斜体字体,但没有定义小型大写字体。我怎样才能做到这一点?
/* A font by Jos Buivenga (exljbris) -> www.exljbris.com */
@font-face {
font-family: "Fontin";
src: url(../Fonts/Fontin-Regular.ttf) format("truetype");
}
@font-face {
font-family: "Fontin";
font-style: italic;
src: url(../Fonts/Fontin-Italic.ttf) format("truetype");
}
@font-face {
font-family: "Fontin";
font-weight: bold;
src: url(../Fonts/Fontin-Bold.ttf) format("truetype");
}
@font-face {
font-family: "Fontin";
font-variant: small-caps;
src: url(../Fonts/Fontin-SmallCaps.ttf) format("truetype");
}
相关:How to add multiple font files for the same font? 和 Properly defining font-family in @font-face CSS rules。
【问题讨论】: