Created attachment 180626 [details]
This happens when there's no text in the line to force line layout, so the block only gets positioned by block layout.
Created attachment 180630 [details]
Comment on attachment 180630 [details]
View in context: https://bugs.webkit.org/attachment.cgi?id=180630&action=review
I'm a little torn about this because our current behavior matches Opera and IE8/9. Your patch makes us match Firefox. Also, if you remove the p element, then all the browsers agree that the text-align should apply. So, I'm inclined to say that this patch is an improvement, but we'll need to watch to keep an eye out for regressions.
> + Abspos Inline block not positioned correctly in text-aligned container
> +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
Can you clean up this test case some?
-Use <!DOCTYPE html>
-use offsetWidth on the container instead of getComputedStyle.
-get rid of id="body"
-don't need to set the font
-make the background a different color than the text, even better, make the p and the reference div have different background colors so it's more clear what's going on
If I were writing this test, I'd also remove the html and head elements, but that's not a universally agreed upon style, so up to you.
Created attachment 184270 [details]
Comment on attachment 184270 [details]
Clearing flags on attachment: 184270
Committed r140570: <http://trac.webkit.org/changeset/140570>
All reviewed patches have been landed. Closing bug.