时间:2021-07-01 10:21:17 帮助过:54人阅读
< b > < i > 是视觉要素(presentationl elements),分别表示无意义的加粗,无意义的斜体,表现样式为 { font-weight: bolder },仅仅表示「这里应该用粗体显示」或者「这里应该用斜体显示」,此两个标签在HTML4.01中并不被推荐使用;
< em > 和 < strong > 是表达要素(phrase elements)。 < em > (emphasized text)表示一般的强调文本,而 < strong > (strong emphasized text)表示比 < em > 语义更强的的强调文本。
i 元素现在描述为在普通文章中突出不同意见或语气或其他的一段文本,例如:一个分类名称,一个技术术语,一个外语中的谚语,一个想法等。或者代表斜体的排版方式
b 元素现在描述为在普通文章中仅从文体上突出的不包含任何额外的重要性的一段文本。例如:文档概要中的关键字,评论中的产品名。或者代表强调的排版方式。
参考内容如下:
They have the same effect on normal web browser rendering engines, but there is afundamental difference between them.
在大多数浏览器的渲染引擎上都是一个效果,但是两者的基础不同
As the author writes in a discussion list post:
Think of three different situations:
有三个不同的应用场景:浏览器、盲人、移动电话
"Bold" is a style - when you say "bold a word", people basically know that it means to add more, let's say "ink" around the letters until they stand out more amongst the rest of the letters.
BOLD 是一种样式,当人们说“加粗一个单词”时,大家会认为增加一些(比如叫墨水)到这些词上以便让这些词看起来比旁边的词更显眼
That, unfortunately, means nothing to a blind person. And on mobile phones and other PDAs, text is already bold because screen resolution is very small. You can't bold a bold without screwing something up.
但是,不幸的是,这对盲人来说毫无作用。而且对手机或者其他的手持设备来说,由于其屏幕的分辨率很小,文本已经被加过粗了,我们也无法再加粗一个已经加粗的了。
is a style - we know what "bold" is supposed to look like.
标签是一种style,我们都知道“加粗”应该长什么样。
however is an indication of how something should be understood. "Strong" could (and often does) mean "bold" in a browser, but it could also mean a lower tone for a speaking program like Jaws (for blind people). And strong on a Palm Pilot may be an underline (since you can't bold a bold).
标签一种对有些事情需要被理解的暗示。“strong” 在浏览器应该(也一般会)意味着bold,但是(对于盲人来说),它就可以被像Jaws一样的语音程序理解成一种强调音。strong在手持设备上可能会是一个下划线(因为你不能在加粗了)。
HTML was never meant to be about styles. Do some searches for "Tim Berners-Lee" and "the semantic web". is semantic - it describes the text it surrounds ("this text should be stronger than the rest of the text you've displayed") as opposed to describing how the text it surrounds should be displayed ("this text should be bold").
HTML从来都不是只意味着样式。去搜一下tim berners-lee 和语义web。标签就是一种语义,它描述的场景是它所包含的内容应该比你显示的其他文本更strong,而不是它所包含的文本应该其他的加粗。