[Webkit-unassigned] [Bug 37261] White space preceding a <br> affects layout of center or right aligned preceding line

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jun 3 20:09:20 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=37261





--- Comment #18 from Xianzhu Wang <phnixwxz at gmail.com>  2010-06-03 20:09:18 PST ---
(In reply to comment #17)
Thanks for your comments.

> A couple of comments:
> 
> (1) As you can see from my original code comment, this behavior of retaining the space before a <br> was actually deliberate.  At the time (many years ago), I was definitely matching some other browser's behavior (probably Firefox).  Have you verified that both IE for Windows and Firefox discard the spaces before a <br>?
> 

I just verified again in other browsers with the attached test case. The results are:
- IE8: spaces before a <br> doesn't affect the layout, but is selectable.
- Firefox 3.6: spaces before a <br> neither affect the layout nor is selectable.
- Opera 10: same as Firefox

According to the standard, I think current Firefox and Opera's behavior is correct. The patch can make WebKit behave like them.

> (2) Have you tested HTML editing with this patch in place?  My concern is that the editing code may open a sequence of alternating nbsps and spaces with a space, and that when you insert a br after that space, that space would suddenly disappear.  It may be that editing opens with nbsp when you first type a space, but it might not.

Just verified that the editing behavior is OK with the patch.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list