【发布时间】:2020-04-20 04:35:27
【问题描述】:
我在我的网站上使用来自 Google Fonts 的 Yanone Kaffeesatz 字体作为标题。当我设置一些轮廓时,原来字体由许多图形组成,每个图形都有自己的笔画。如何让它看起来完整?
h2 {
font-size: 3.5em;
font-family: 'Yanone Kaffeesatz', sans-serif;
color: #25D366; /* also tried -webkit-text-fill-color: #25D366; - same effect */
-webkit-text-stroke: 1px black;
letter-spacing: 0.05em;
/*paint-order: fill stroke; - also tried - no effect */
}
<link href="https://fonts.googleapis.com/css2?family=Yanone+Kaffeesatz:wght@500&display=swap" rel="stylesheet">
<h2>Hello</h2>
【问题讨论】:
-
它看起来像一个特定的 Yanone 字体错误(在
Roboto、open-sans等上运行良好)。现在,使用text-shadow(@kosh 回答)。
标签: css fonts stroke google-fonts