Linux FF 和 Windows FF 中的字体不同

发布于 2024-09-11 06:43:13 字数 351 浏览 2 评论 0原文

请检查此屏幕截图!

替代文本 http://img267.imageshack.us/img267/1391/difference.png< /a>

这是Linux FF(左侧)和Windows FF(右侧,IE 中显示方式相同)中的同一页面。我喜欢它在 Linux FF 中的外观,并希望在 Windows 中也有同样的外观。然而,在尝试了我所知道的所有 CSS 属性之后,我没能改变它在 Windows 中的外观。您是否知道这个问题的任何解决方案?

Please check this screenshot!

alt text http://img267.imageshack.us/img267/1391/difference.png

This is the same page in Linux FF (on the left) and Windows FF (on the right, also it's displayed in the same way in IEs). I love how it looks in Linux FF and want to have the same look in Windows. However after playing with all CSS properties I know of, I didn't manage to change its look in Windows. Do you by chance know any solution for this issue?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

一向肩并 2024-09-18 06:43:14

以防万一:作为一名网页设计师,您无法逐个像素地控制您的网站在用户浏览器上的显示方式。打印和 PDF 非常适合此目的,而不是网络 :)

Cleartype 在 Windows 上激活吗?这会极大地改变显示效果,并且由用户决定是否激活此功能:如果他不喜欢抗锯齿,您会通过强制渲染来激怒他,我们可以在左侧看到!

您还可以更改 font-family 中的字体堆栈并添加 Arial 以外的其他字体。

Just in case: as a webdesigner you can't control pixel per pixel how your site will display on your user's browsers. Print and PDF are great for that purpose, not the web :)

Is Cleartype activated on Windows? This changes the display a lot and it's the user decision to activate or not this feature: if he doesn't like antialiasing you'd piss him off by forcing the rendering we can see on the left!

You can also change your stack of fonts in font-family and add other fonts than Arial.

流星番茄 2024-09-18 06:43:14

您无法决定用户的字体的外观。字体的确切选择以及是否抗锯齿是客户端设置。有些人(可怕的卢德分子,我认为)更喜欢像素化的外观。无论如何,Linux 很可能使用类似的后备字体(例如“Sans”)而不是 Arial 本身,因此它永远不会看起来完全相同。

要在 Windows 中为大多数字体(在所有应用程序中,而不仅仅是 Web 浏览器中)打开抗锯齿功能,您需要 启用 ClearType。如果没有 ClearType,Windows 的抗锯齿功能就是旧的、损坏的“字体平滑”选项,对于大多数字体来说,该选项效果很差,以至于 Windows 宁愿不使用它。 ClearType 渲染与 Linux 将使用的抗锯齿渲染并不完全相同;通常它仅在水平方向上抗锯齿。因此,它看起来不太一样,但通常认为至少对于拉丁字母来说相当不错。

如果您真的迫切希望从服务器端推送它,您可以使用 @font-face 规则来嵌入一种字体,该字体已将 GASP 表修改为始终使用抗锯齿功能(使用 ttfgasp .exe 或字体编辑器)。然而,对 Arial(或者实际上大多数没有开放许可证的字体)执行此操作在技术上是不合法的。

You don't get to decide how the user's fonts look. The exact choice of font and whether it is anti-aliased is a client-side setting. Some (terrible luddites, IMO) prefer the pixellated look. In any case, Linux is likely to be using a lookalike fallback font (eg. ‘Sans’) rather than Arial itself, so it's never going to look exactly the same.

To turn anti-aliasing on in Windows for most fonts (in all applications, not just web browsers), you need to enable ClearType. Without ClearType, Windows's anti-aliasing is the old broken ‘font smoothing’ option, which for most fonts is so poor that Windows prefers not to use it. ClearType rendering isn't quite the same as the anti-aliasing Linux will be using; usually it only anti-aliases in the horizontal direction. So again it won't quite look the same, but it's generally considered pretty good at least for the Latin alphabet.

If you're really desperate to push it from the server side, you could use a @font-face rule to embed a font that has the GASP table hacked to always use anti-aliasing (using a ttfgasp.exe or a font editor). However doing this to Arial (or indeed most fonts without an open licence) would not be technically legal.

沒落の蓅哖 2024-09-18 06:43:14

通过在 Windows 中激活字体平滑功能,您可以轻松获得相同的外观(或至少相似)。但是,您无法使用 CSS 激活它。

在较新版本的 Windows 中,字体平滑功能默认处于启用状态,因此许多访问者会看到它,就像您在 Linux 系统上看到的一样。

这是用户设置,理应如此。每个用户应该能够在他/她的显示器上选择最适合他/她的平滑设置。

如果您绝对希望每个用户的文本看起来都像 Linux 系统上的那样,那么您唯一的选择就是将其设为图像。

You can easily get the same look (or at least similar) by activating font smoothing in Windows. You can not, however, activate it using CSS.

Font smoothing is on by default in newer versions of Windows, so a lot of visitors will see it as you see it on your Linux system.

This is a user setting, and that is as it should be. Each user should be able to choose the smoothing setting that works best for him/her on his/her monitor.

If you absolutely want the text to look like on your Linux system for every user, your only option is to make it an image.

小兔几 2024-09-18 06:43:14

不同版本的Windows和Linux,甚至字体渲染系统的不同设置,都会产生不同的字体渲染结果;在第一种情况下,针对 LCD 的子像素优化的抗锯齿功能明显被激活,而在第二种情况下,甚至没有启用抗锯齿功能。

为了在 Windows 上获得更好看的字体渲染,您应该启用 ClearType。无论如何,这都是客户端设置,而且据我所知,您无法从 HTML 为它们做任何事情 - 而且您不能这样做,如果用户不喜欢抗锯齿,您就不应该弄乱他的设置。

Different versions of Windows and Linux, and even different settings of their font rendering systems, yield different results in font rendering; in the first case antialiasing with subpixel optimizations for LCDs is clearly activated, while in the second case not even antialiasing is enabled.

To get nicer looking font rendering on Windows you should enable ClearType. In any case, it's all a client-side settings, and AFAIK you can't do anything for them from HTML - and you mustn't, if the user don't like antialiasing you shouldn't mess with his settings.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文