Re: Class Selectors Extension Proposals

On Thu, 16 May 2002 13:32:11 +0200, you wrote:

>Alberto Pacheco wrote:
>> Does CSS support the following class descriptors functionality?
>> 1) Adding classes
>>     Let be
>>         .a { p1; }
>>         .b { p2; }
...

>Just write <span class="a b">.

Correct.

>>  2) Parametrized classes
>>     How do I get something like:
>>         .c(X,Y) { width:X; color:Y; }
>>     To be refered in HTML later as:
>>         <span class="c(50%,red)">
>>     Where class c becomes equivalent to ".c { width:50%; color:red;)"
>> I know it sounds crazy...

Yes it is, but maybe not from the road you are coming...

>Oh ! That one is interesting and not so crazy. We already have 
>pseudo-classes accepting parameters, so why not classes (theoretical 
>question only)...

It is "crazy", based on the original idea that CSS is a
_descriptive_only_ language. It should in an ideal situation not contain
anything that even resembles function calls that goes beyond fixed 1:1
routines as implemented in user agents.

I.e. CSS _shall_never_ be allowed to be looked on as a sort of
"programming language". We have e.g. FOSI, DSSSL and XSLT to handle such
more complex things where ever they may be needed.

Please, let CSS stay as something that can be _described_ to people in
general in a way where they can grasp the fact that it's only about a
suggested presentation and nothing else.

It was supposed to be "typography on the web" from the start of it,
(words said to me from at least one of the original creators of CSS) why
is it necessary to molest that original idea?

>Anyway, I think it deserves to be added to the CSS Suggestions List...

Do _not_ add any more types of "procedure/function calls" to CSS than
what is already there in CSS2. Instead spend serious time on that
"promised" CSS2.1 spec. The world of users and authors needs it,
implementors needs it, don't you?

Or is "constant earthquake" the real future?

-- 
Rex [the fox in the chicken shack]

Received on Thursday, 16 May 2002 18:27:25 UTC