Re: [css3-background] background-size vs background-stretch

Well, fantasai says this should get some designer feedback, so here  
goes...

background-stretch, background-resize, etc... all strike me as  
ambiguous and unclear.  As much as possible, the properties' names  
should make self-evident what they are referring to.  I think it is a  
safe bet that many of us tend to use wrapper divs a lot and think of  
those as the background area.  Adding properties for a distinct  
background area will make us rethink the way we code anyway, so why  
not use background-size for that, and use background-fill-size for the  
image or other element?  That way it will be clear what we are  
referring to, even though it will force us to go look up the spec at  
first.

Also, by using fill, it could possibly add a little flexibility that  
could be extended into some interesting results.

Ignore me if I am off-base here, but that whole stretch, resize idea  
just bothers me.

Peace,
Todd Russell

On Jan 18, 2008, at 4:45 PM, David Hyatt wrote:

>
> I don't like background-resize either.  In the case of images with  
> no intrinsic size (e.g., SVG), you aren't resizing.  You're just  
> setting an explicit size.  I don't see any issue with the name  
> background-size.  I don't think it's confusing at all.
>
> dave
>
> On Jan 18, 2008, at 4:13 PM, fantasai wrote:
>
>>
>> Anne van Kesteren wrote:
>>> On Fri, 18 Jan 2008 21:17:37 +0100, fantasai <fantasai.lists@inkedblade.net 
>>> > wrote:
>>>> A comment in the spec says:
>>>>
>>>> # Is ‘background-stretch’ a better name? People also suggested to  
>>>> use
>>>> # ‘background-stretch: none’ instead of ‘auto’ in that case.
>>>>
>>>> I think we should go with 'background-stretch'. It gives a clearer
>>>> idea of what the property does: background-size could be  
>>>> interpreted
>>>> as setting the size of the background area, not the size of the  
>>>> image.
>>>> I'd keep 'auto' as the initial value though, especially since  
>>>> scalable
>>>> images (aspect ratio, no height/width) will always be stretched.
>> //
>>> we already have various background-* properties specifically for the
>>> background image, such as background-position, background-repeat  
>>> and background-attachment so I don't think it will be interpreted  
>>> as being for something else.
>>
>> We also have background-clip and background-origin, which set  
>> parameters
>> on what to interpret as the boundaries of the background area.
>>
>> > I agree with David Hyatt. background-size is clearer name
>>
>> Web designers need terms that are more evocative even if they are  
>> less
>> exact. E.g. we picked 'image-position' as a name instead of
>> 'replaced-element-position' even though it applies to plugins and  
>> other
>> replaced elements, not just images, because it allows designers to  
>> more
>> easily relate to what it means. I think either "background-stretch"  
>> or
>> "background-resize" would be more likely to suggest the right idea  
>> than
>> the current term.
>>
>> This is really a question for web designers, though, not for us.
>>
>> ~fantasai
>>
>
>

Received on Friday, 18 January 2008 23:20:21 UTC