[webkit-reviews] review requested: [Bug 20461] Collapse multiline values in inputs : [Attachment 23306] Possible fix to bug 20461

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Sep 9 17:46:06 PDT 2008

Glenn Wilson <gwilson at google.com> has asked  for review:
Bug 20461: Collapse multiline values in inputs

Attachment 23306: Possible fix to bug 20461

------- Additional Comments from Glenn Wilson <gwilson at google.com>
Here is a potential fix to this problem.

This bug is the result of an earlier issue wherein pasting text with multi-line
inputs would result in text areas mis-sizing.  The solution was to simply
truncate all input after the first non-tab system character had been found.

I believe that this behavior is not entirely correct.  Other browsers do not
truncate after the first system character, but simply replace newlines with
spaces.  This seems to be helpful to the user: for example, copy a two-line
postal address and paste into Google Maps' one-line text field.  This change
modified how the input filter replaced text: it now replaces newlines and
carriage returns (and the combination, \r\n) with a single space.

However, not all behavior has been changed.  The input still truncates on
non-tab, non-carriage return, non-newline system characters.

As a result, a layout test has been added and the old layout test has been

More information about the webkit-reviews mailing list