css - Font-Face Firefox 5/7 — 仅限 Windows — 难看的颜色

标签 css windows font-face firefox-5

我使用带有 font-face 的自定义字体,它在除 Windows 上的 Firefox 之外的所有浏览器中都运行良好。字体的颜色应该是灰色#666。但它看起来是粉红色的!知道如何在 win 机器上避免 FF 中这些难看的颜色吗?

screenshot: Adobe BrowserLab

screenshot: Adobe BrowserLab enlarged

最佳答案

编辑: 评论表明这是字体问题而不是颜色问题,仔细查看示例后我同意。这是极端 Cleartype 平滑的示例 - 绿色不受影响,而红色和蓝色已被弱化以使线条显得更细。由于背景是白色,这种弱化使红色和蓝色变浅,从而产生粉红色/洋红色调。

Cleartype 背后的理论是,这些操作应该几乎是不可见的,看看你未缩放的例子,我会说色调非常微妙。只有当你把它炸毁时,它才会变得明显,至少在我的显示器上是这样。

可能有一种方法可以在您自己的系统上调整 Cleartype,但这在整个网络上都行不通。唯一的解决办法是更改字体本身的提示,这样它就不会尝试制作如此细的垂直线。


尝试使用颜色 #666666 而不是 #666

来自 Wikipedia :

An abbreviated, three (hexadecimal) digit form is sometimes used. Expanding this form to the six-digit form is as simple as doubling each digit: 09C becomes 0099CC. This allows each color value to cover its full range from 00 to FF. The three-digit form is described in the CSS specification, not in HTML. As a result, the three digit form in an attribute other than "style" is not interpreted as a valid color in some browsers.

关于css - Font-Face Firefox 5/7 — 仅限 Windows — 难看的颜色,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7732662/

相关文章:

php - start/B 不启动任务

javascript - 从 Dropbox 访问字体时出现 CORS 错误

internet-explorer-8 - 在 IE8 中嵌入 FontAwesome 字体时出现 CSS3111 错误

css - 多个@font-face 在 IE9–11 或 Firefox 中不工作

javascript - 悬停时没有颜色

html - 当我将 html 复制到 wordpress 时,为什么我的元素垂直移动?

html - 如何将列表项与 svg 多边形对齐?

javascript - 使用图像而不是未打开的 <select>?

c# - 如何制作具有用于管理它的任务托盘图标的 Windows 服务?

c++ - 为什么 EnumWindows 返回的窗口比我预期的要多?