Re: [csswg-drafts] [cssom-view] Layout dimension that divides+rounds+sums to value greater than original dividend

Thanks for looking into this and writing tests! This is indeed the right place.

Although the rendering can snap to device pixels, this can still be different from CSS pixels. In particular if there are two device pixels per CSS pixels (in one dimension), then both columns can be exactly 49.5px (without aliasing). Also with page zoom can affect this I believe.

Still, you demonstrated that there is lack of interop between Chrome and everyone else, so it would be good to come to an agreement which behavior is better and align on that.

If we say that all widths should add up to the same sum as the total width, how could that be implemented? For Firefox and Edge that allow the edge to cross a pixel, it seems they would need to do extra work to figure out which way to round `offsetWidth` for any given element, which seems both complex and expensive.

So I'm tempted to suggest that these should round in isolation (like Safari/Firefox/Edge), and we can add new non-integer APIs if any are missing.

@rune-opera thoughts?

-- 
GitHub Notification of comment by zcorpan
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1211#issuecomment-293819169 using your GitHub account

Received on Thursday, 13 April 2017 07:53:53 UTC