- From: Leif Arne Storset <lstorset@opera.com>
- Date: Wed, 01 Feb 2012 16:19:07 +0100
- To: "www-style@w3.org" <www-style@w3.org>
Leif Arne Storset <lstorset@opera.com> skreiv Wed, 01 Feb 2012 15:34:06 +0100 > In section 5.4, the definition for 'object-fit: fill' currently contains: > > # Set the object's size to the concrete object size obtained by running > # the object sizing algorithm with a specified size and a default object > # size equal to the replaced element's used width and height. > # > - This will make the contents exactly fill the replaced element's > - content box. > > This statement will probably be interpreted too strongly. For example, an > SVG image with preserveAspectRatio not set to "none" will be given the > entire content box of the replaced element to render in, but it will > actually only render into an area that will maintain the aspect ratio. > [0] > > Of course, if the reader consults section 5.2. "CSS⇋Object Negotiation", > step 3, the correct behavior is specified there. However, I think it's > good to be clearer about the behavior here. > > Note that Opera's implementation (AFAIK the only of the two that is > easily > obtainable) does not currently match the spec in this respect. (Or > rather, > it matches the overly-strict interpretation of the paragraph quoted > above.) > > Suggested wording: > > # Set the object's size > [...snip rest of paragraph...] > # > + This will allow the object to fill the replaced element's content box. > + > + NOTE: However, the object may choose to render at a smaller size, as > + mentioned in section 5.2. For example, an SVG image will usually > + preserve its aspect ratio even if 'fill' is specified. Suddenly I see that there's a note to this effect at the end of section 5.4. My suggested note can probably be dropped, though I maintain my suggested rewording. -- Leif Arne Storset Core Technology Developer, Opera Software Oslo, Norway
Received on Wednesday, 1 February 2012 15:19:36 UTC