W3C home > Mailing lists > Public > www-style@w3.org > January 2006

Re: Regarding Comma Separation

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Tue, 17 Jan 2006 00:23:34 -0800
Message-ID: <003401c61b3f$515fa4b0$3201a8c0@Terra>
To: "Kelly Miller" <lightsolphoenix@gmail.com>, "HeroreV" <herorev@yahoo.com>
Cc: "W3C Style List" <www-style@w3.org>

From: "Kelly Miller" <lightsolphoenix@gmail.com>

> HeroreV wrote:
>> The new arrays in the CSS-OM could have plural names.
>> Setting a value for backgroundImages[0] would also set
>> a value for backgroundImage.
>
> Yeah, even that is better than using a comma-separated list of values. 
> The syntax for background: is already really ugly, and it's only going to 
> get more ugly as properties are added.  Making it a comma list will 
> multiply that by a huge factor.

Agree about commas. What if number of elements in two
lists will not match? E.g. background-image(s) and background-position(s)...

I think the problem we are encountering now is in lack of modularity of CSS
style system itself. Attempt to put everything in flat name/value table work 
on
simple cases but now...

Back to background. Set of values of different background attributes defines
some backround method. Values of such attributes are dependable from each 
other.
It makes no sense to have them separated and inherited independently as they
reperesent parameters of single function in fact.

Ideally solution should be close to this:

background-method: tile-image( src: url(...), offset-x: 3px; ...  );
background-method: fixed-image( src: url(...), position-x: 3px; ...  );
background-method: stretched-image( src: url(...), ...  );
background-method: bordered-image( src: url(...), margin-left:3; 
margin-right:10  );

The same for
foreground-method: ....

Having this the whole design will be more stable and naturally extendible
now and in the future.

Andrew Fedoniouk.
http://terrainformatica.com
Received on Tuesday, 17 January 2006 08:23:53 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:42 GMT