W3C home > Mailing lists > Public > www-style@w3.org > November 2011

Re: [css3-images] aliases for 'cover' and 'contain'

From: fantasai <fantasai.lists@inkedblade.net>
Date: Fri, 04 Nov 2011 13:02:44 -0700
Message-ID: <4EB444E4.7030509@inkedblade.net>
To: www-style@w3.org
On 11/04/2011 09:38 AM, Tab Atkins Jr. wrote:
> On Thu, Nov 3, 2011 at 11:54 PM, fantasai<fantasai.lists@inkedblade.net>  wrote:
>> The radial-gradient() spec defines 'cover' as an alias for 'farthest-corner'
>> and 'contain' as an alias for 'closest-side'.
>> We generally try to avoid aliases in CSS, why do we have these here and
>> can we remove one of the pairs?
> Blame my youthful naivete.  I originally created the closest/farthest
> keywords, and then thought that reusing bg-size's cover/contain
> keywords would be more intuitive, so I had them both.
> I know I've seen usage of both forms in the wild.

Hm. So I'd suggest dropping cover/contain, and adding them back when we
have asymmetrical radials. Then

radial-gradient(from 25px 25px to cover, blue, transparent)

could represent a centered ellipse that covers the box and has a gradient
focus at 25px 25px.

Received on Friday, 4 November 2011 20:03:18 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:06 UTC