Re: [css3-values] attr() function

* Orion Adrian wrote:
>I think it's unreasonable to think that languages will always use the
>CSS color syntax. There will always need to be some sort of conversion
>function. With HTML4, it's fairly simple, but even so, there's no
>conversion function even for something as simple as putting a # in
>front.

This is true, X3D for example uses a list of float for colors, for
Avalon objects in XAML you can use #rrggbbaa, other languages like
SVG don't even share the same model (you'd specify the fill color
and the fill opacity separately); for other data types there are
similar issues, resource identifiers in attributes typically don't
use the url() functionality notation, float values might allow for
a 'scientific notation' and so on.

I don't see how this matters here though, the cases where you'd want
to use styling attributes and CSS for the same document and actually
can because the styling model is sufficiently similar seem uncommon.
Some features in CSS require attr() and it has proven useful for
e.g. mapping legacy styling attributes like those in HTML to CSS in
some user agents, and making it more general purpose does not add
significant overhead to CSS implementations; but it's not meant to
be an ubiquitous feature.
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 

Received on Tuesday, 2 August 2005 13:53:24 UTC