CSS3: Proposal for image cropping and scaling syntax

In respect to the recent discussion on extended tiling the issue of 
packaging multiple files into a single image came up. There was also a 
proposal for using some sort of data file to use parts of one big image.

I propose that one could consider a generic syntax for cropping and 
scaling an image. This way one could use parts of one big image as 
individual backgrounds, and thus have an inherit packaging format.

The A List Apart article CSS Sprites by Dave Shea partially demonstrates 
the idea in action: http://www.alistapart.com/articles/sprites/


Current CSS does not, however, allow for a great deal of flexibility 
with this approach. If it were possible to generically crop and scale an 
image, a single image file could potentially contain any number of small 
symbolic images and/or backgrounds used on a page.

This would also do away with the need for the crop property, Unless 
someone actually feels a need to crop other things than images:
http://www.w3.org/TR/2002/WD-css3-box-20021024/#the-crop


Providing that the syntax would allow for cropping and scaling part of 
an image in any place where an image could otherwise be used this would 
essentially solve the packaging format issue, as well as provide 
additional flexibility.


This idea may have and probably has several major flaws. Feel free to 
shoot it down if you have the proper argumentational ammuntition.

-- 
Max Romantschuk
http://max.nma.fi/

Received on Friday, 7 May 2004 04:43:47 UTC