Re: suggestion: fixed-aspect-ratio CSS rule for block elements

On Thu, May 6, 2010 at 11:42 PM, James Elmore <James.Elmore@cox.net> wrote:

> Another point -- the pair of integers could be specified as "width, height"
> or even "width height". And what if an author uses a non integer (ddd.dd)?
> is that an error, or is the second number ignored, or is the ratio still
> used. SVG users would expect the numbers to be used, even if they were not
> integers. I hope CSS follows that path.
>

I agree some people could want aspect-ratio: 1.6 / 0.9 to work. I would go
further and say negative numbers could be allowed as long as both numbers
are negative (so the outcome is always positive), i.e. -16 / -9 works too.

Now, the only case I see where this would be useful is when the property is
generated from inside a script, so the developer doesn't have to perform
range reduction on the values. Convenient, but is it really needed?

Julien.
-- 
Julien Cayzac
http://julien.cayzac.name/
skype://jcayzac?chat

Received on Saturday, 8 May 2010 01:31:53 UTC