本文介绍了属性“风格”的改进的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您对属性样式感兴趣多少?将提供

相同或类似的功能,如元素提供的

" style"在元素head中?


您是否希望文档CSS语法规则为HTML的样式

属性" ; ()将在不久的将来成为

官方推荐?


祝你好运,

Markus Elfring

How much are you interested that the attribute "style" will offer the
same or similar capabilities like they are provided by the element
"style" in the element "head"?

Do you want that the document "Syntax of CSS rules in HTML''s "style"
attribute" (http://www.w3.org/TR/css-style-attr) will become an
official recommendation in the near future?

Best regards,
Markus Elfring

推荐答案




不多。理想情况下,应该没有属性样式。在HTML中。它b / b
诱惑作者只重复HTML / 3.2的废话,只是用一种更加冗长的语言。



Not much. Ideally there should be no attribute "style" in HTML. It
tempts authors to just repeat the nonsenses of HTML/3.2, just in a
more-verbose language.





我可以看到一些向后兼容性的问题。

采取他们的第二个例子:

< p style =" {color:#090; line-height:1.2}

::第一个字母{color:#900}"> ...< / p>

人们希望符合CSS1或CSS2的浏览器将应用

颜色和行高属性,并忽略CSS3 :: first-letter

语法。但是这里提出的语法包含{}

意味着较旧的(换句话说当前的)浏览器会忽略所有

样式。不太理想。


该文件已有近两年的历史,还有进一步的工作吗?

就此而言?或者你只是想把死人抬起来?


史蒂夫


-

"我的理论appal你,我的异端邪说你愤怒,

我从不回信,你也不喜欢我的领带。 - 医生


Steve Pugh< st *** @ pugh.net> < http://steve.pugh.net/>



I can see some problems with backwards compatability.
To take their second example:
<p style="{color: #090; line-height: 1.2}
::first-letter {color: #900}">...</p>
One would hope that a CSS1 or CSS2 compliant browser would apply the
color and line-height properties and ignore the CSS3 ::first-letter
syntax. However the syntax proposed here with the inclusion of {}
means that older (in other words current) browsers ignore all the
styles. Not ideal.

That document is nearly two years old, has any further work been done
on this? Or are you just trying to raise the dead?

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don''t like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>





不多。理想情况下,应该没有属性样式。在HTML中。它b / b
诱惑作者只重复HTML / 3.2的废话,只是用一种更加冗长的语言。



Not much. Ideally there should be no attribute "style" in HTML. It
tempts authors to just repeat the nonsenses of HTML/3.2, just in a
more-verbose language.


这篇关于属性“风格”的改进的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-30 07:21