W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2011

[whatwg] textarea newline format - raw value vs. transformed value and setSelectionRange

From: Michael A. Puls II <shadow2531@gmail.com>
Date: Tue, 03 May 2011 01:49:18 -0400
Message-ID: <op.vuv44gde1ejg13@sandra-svwliu01>
On Mon, 02 May 2011 19:21:26 -0400, Ian Hickson <ian at hixie.ch> wrote:

> On Tue, 4 Jan 2011, Michael A. Puls II wrote:
>>
>> But, what happens when pressing ENTER in a textarea? Should it always
>> create a \n in the raw value? What if you paste content that has "Line
>> 1\r\nLine 2" in an empty textarea area? Will the raw value contain "Line
>> 1\nLine 2" then?
>
> I've clarified the spec to indicate explicitly that U+000A is what should
> be inserted for a line break when the user edits the page. The behaviour
> when the user pastes a U+000D into a textarea is up to the UA, but could
> include inserting the U+000D.

Thanks

-- 
Michael
Received on Monday, 2 May 2011 22:49:18 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:32 UTC