Re: Idea: background-image-frame attribute

This is simply another small part of a large issue that has existed 
since the background properties were added to CSS; no one planned for 
needing to do anything more complicated with background images than the 
standard defined before.  Now, when people ask for improvements to 
background images, the problem IS the way backgrounds have been 
traditionally represented in CSS.

I still believe that background images would be much more useful if they 
were treated like clipped positioned layers under (and over, if we're 
talking about foreground images) the element itself, using properties 
that map to top, bottom, right and left in positioning.  That plus 
background-clip and multiple backgrounds would handle 99% of all 
background-image use cases; and most of the missing have to do with 
positioning based on a common ancestor, which I don't think could be 
done easily in CSS.

The problem being run into now is that background-position is inadequate 
for background positioning, because it always positions from the top 
left unless keywords are used, and it assumes you want to use ALL of the 
image.  It lacks stretching, clipping and the ability to position based 
on coordinates other than Cartesian (0,0).

Interestingly enough, most of these problems are solved in regular 
positioning; and I'd say it's probably time that the whole 
background-image system should be treated as if each image is a 
positioned layer.  In fact, such treatment would enable one to do unique 
things with background images, one of which is making background images 
appear OVER content instead of under (thereby avoiding the need for a 
foreground image replacement technique, though content is useful for 
more than that).

-- 
http://www.mozilla.org/products/firefox/ - Get Firefox!
http://www.mozilla.org/products/thunderbird/ - Reclaim Your Inbox!

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html

Received on Sunday, 1 January 2006 22:50:41 UTC