|
Posted by Andy Dingley on 11/07/38 11:51
jojo wrote:
> ASFAIK their is a order in which color, formats, font-style and so on
> are used:
There's no "order" in CSS. Instead there is a cascade, with specificity
rules and calculations. This needn't give rise to a simple linear order
in all cases, it's more complex than that.
> Specified by style-Attribut
> Specified by font-tag
> Specified in internal Stylesheets
> Specified in external Stylesheets
As you describe it here, <font> (and some other HTML presentational
information) gets treated as lower than the stylesheets too. A browser
can also ignore them entirely, should it wish to (i.e. a pure CSS
browser).
Here's the ref:
http://www.w3.org/TR/CSS21/cascade.html#q13
"The UA may choose to honor presentational attributes in an HTML source
document. If so, these attributes are translated to the corresponding
CSS rules with specificity equal to 0, and are treated as if they were
inserted at the start of the author style sheet."
Navigation:
[Reply to this message]
|