W3C home > Mailing lists > Public > www-svg@w3.org > March 2009

RE: 'image-fit' vs preserveAspectRatio

From: Grant, Melinda <melinda.grant@hp.com>
Date: Wed, 18 Mar 2009 01:07:11 +0000
To: Simon Pieters <simonp@opera.com>, "www-style@w3.org" <www-style@w3.org>, "www-svg@w3.org" <www-svg@w3.org>
Message-ID: <763AE400FE923441B74861D534DF25495DED2823AA@GVW0433EXB.americas.hpqcorp.net>
 
Hi Simon,

I know little about SVG, so maybe someone else will help out if I misspeak.

> The CSS property allows the same precision as 
> 'background-position' for positioning, while SVG has less 
> precision. What are the use cases for more precision?

I think the greater precision for positioning was driven more by a desire to align with existing CSS syntax than from identified use cases.  The greater flexibility may not afford significant advantage to CSS authors.

> The CSS spec allows the image to go outside of the layout box 
> with 'overflow:visible; image-fit:cover'. What's the use case 
> for this?

This is more driven by the CSS box model than by use cases, I believe.  Images can extend beyond their height/width boxes, and overflow is the mechanism to control that.  The 'image-fit' specification just uses the existing model.  (I don't think SVG has a similar overflow model, does it?)

> Previously, the CSS spec had the same keywords as SVG. What's 
> the reason for the change?

The keywords were initially taken from SMIL 1.0, but it was felt that the functionality was different enough that we should use different names to prevent confusion.  Also, the CSS group felt that the previous keywords weren't as descriptive as they could be.

HTH,

Melinda
Received on Wednesday, 18 March 2009 01:08:59 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:41 GMT