Re: [css3-flexbox] Bad result in flex algorithm when combining stretch, and elements with an aspect ratio

(12/10/28 23:51), Tab Atkins Jr. wrote:
> Any objections?  Otherwise, I'll edit the flexbox layout algorithm
> with the following two changes:
> 
> 1. Add a bullet point to step 3 (hypothetical main size determination)
> to handle aspect-ratio items with "stretch" alignment (so they get the
> correct hypothetical main size).

I am not getting this part. Are you saying that the *correct*
hypothetical main size of <image> in the above example is 50px? Why?
That doesn't feel right to me....

> 2. Modify step 9 (handling "stretch" alignment) to have an explicit
> statement about handling aspect-ratio items, to clarify that it
> changes the cross-size *while ignoring the aspect ratio*, so the main
> size doesn't change.

This is easier to understand. 'align-self: stretch' has contradicted CSS
2.1 already. For example, a 'height: auto; align-self: stretch;' flex
item would already fail the CSS 2.1 requirement for a non-replaced
element with 'height: auto' saying that the height is the sum of heights
of blocks or lineboxes inside. Therefore, "honoring aspect ratio", being
a requirement for a replaced element with 'height: auto;' , would
similarly fail to be be satisfied.



Cheers,
Kenny
-- 
Web Specialist, Oupeng Browser, Beijing
Try Oupeng: http://www.oupeng.com/

Received on Monday, 29 October 2012 06:53:48 UTC