如果我们在网站设计中只使用网络安全字体,对可访问性和可用性有好处吗?
我们是否应该尽可能多地使用默认的网络安全字体,是否应该尝试仅使用网络安全字体来做出好的设计?
表明我们在设计中避免使用花哨的字体,这只有通过任何图像替换技术、sIFR、@Font-face、Typeface 等才能实现,
以实现更好的网站维护、可访问性和可用性
Should we use default web safe fonts as much as possible, should try to make good design with web safe fonts only?
Show we avoid fancy fonts in design which would be only possible with any image replacement techniques, sIFR, @Font-face, Typeface etc.
for better site maintenance, accessibility, usability
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
是的,您应该使用“网络安全”字体。始终在声明末尾包含“通用”字体说明符,例如,
如果您使用图像作为文本元素(例如首字下沉),则屏幕阅读器不会拾取这些图像,更糟糕的是,会将另一个图像放在屏幕阅读器需要 alt 属性的页面。
Yes, you should use "web-safe" fonts. Always include a "general" font specifier at the end of your declaration, like
If you use images for textual elements like drop caps, for example, those won't be picked up by screen readers and, worse, will put another image on the page for which the screen reader will expect an alt attribute.
我想说要利用 @font-face 等,但肯定有一组安全的后备字体。只要你这样做,就不会出错,因为布局永远不会真正取决于字体。
I'd say to take advantage of @font-face and the like, but definitely have a safe set of fallback fonts. As long as you do that, you can't go wrong, since layout never really depends on font.
我不确定使用网络安全字体是否更易于访问、使用或维护。但这绝对是一个很好的做法。根据您选择的字体,您将获得它们具有相当可读性的好处。
坚持使用“网络安全”字体的一般原因是您可以相当确定用户将拥有它(或其中之一)。这可以让您很好地了解在不同操作系统/浏览器等上查看时网页的外观。这一点很重要,因为在某些设计中,不同比例的字体可能会对页面的整体布局造成严重破坏。
还值得确保的是(因为操作系统通常不会在它们之间共享太多字体),您可以通过 CSS 属性
font-family
指定许多不同的字体。例如:但是,辅助功能指南确实指出,您应该避免使用图像来显示文本。这是一个很好的经验法则,因为并不是每个人都能看到图像(搜索引擎和视障人士)。因此,如果您希望每个人都“看到”图像的内容,请使用适当的标记(例如
img
标记上的alt
和title
属性,或者仔细的 CSS / JavaScript 工作来相应地隐藏或显示您的图像/文本。I'm not sure keeping to web-safe fonts is more accessible, usable or maintainable. But it definitely is good practice. And depending on which fonts you choose, you will get the benefit that they are fairly readable.
The general reason to stick with 'web-safe' fonts is that you can be fairly sure that the user will have it (or one of them). This gives you a good idea of exactly how your webpage will look when viewed on different operating systems / browsers / etc. Important because in some designs, differently proportioned fonts can cause havoc with the overall layout of the page.
It's also worth ensuring (because operating systems don't generally share too many fonts between them) that you specify a number of different font's via the CSS attribute
font-family
. E.g:Accessibility guidelines do state however, that you should avoid using images to display text. This is a great rule of thumb, as not everyone can see images (search engines and the visually impaired). So if you want the content of your image to be 'seen' by everyone, use proper tagging (e.g.
alt
andtitle
attributes onimg
tags, or careful CSS / JavaScript work to hide or display your image / text accordingly.