W3C home > Mailing lists > Public > www-style@w3.org > November 2010

Re: [css3-background] New use case for background-position-x (&y!)

From: Brad Kemper <brad.kemper@gmail.com>
Date: Tue, 9 Nov 2010 07:43:39 -0800
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>, www-style@w3.org
Message-Id: <086F8AD7-32D3-4801-BD5B-B7A096ACE295@gmail.com>
To: Lee Kowalkowski <lee.kowalkowski@googlemail.com>

On Nov 9, 2010, at 2:50 AM, Lee Kowalkowski wrote:

>> These are the hallmark of something that only works accidentally.
>> That's what we call a "hack".  ^_^
> 
> It's *not* working accidentally though, is it?  The usage of
> background-position is working in a predicatble and expected way, and
> in accordance with the specification.

It is "accidental" because it takes advantage of a side effect of the spec. The spec was designed to show a background image that can be tiled or not. It was not designed to show show completely different images based on where the tiling begins. You are free to use it that way if you wish, but that was not a guiding principle when writing the spec, and is still not a guiding principle when altering the spec.

[...]

>> You are not intrinsically serving a 2d array; that's just a detail of
>> your particular use-case.  Having a rule for each rank and a rule for
>> each suit isn't part of your requirements; your requirements are to
>> serve a different background-image for each of your 52 cards.  They
>> just happen to have a particular organization.
> 
> Hmm, how I wish to organize my images though is my choice and no
> business of anyone elses.

Sure. Do whatever you like. Just don't expect the spec to change because of it.
Received on Tuesday, 9 November 2010 15:44:15 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:34 GMT