W3C home > Mailing lists > Public > whatwg@whatwg.org > June 2010

[whatwg] Why there is no wrap="off", intentional or forgotten?

From: Lachlan Hunt <lachlan.hunt@lachy.id.au>
Date: Wed, 02 Jun 2010 16:10:39 +0200
Message-ID: <4C06665F.6030205@lachy.id.au>
On 2010-06-02 13:05, Ashley Sheridan wrote:
> On Wed, 2010-06-02 at 12:51 +0200, Old?ich Vete?n?k wrote:
>> I'm missing the wrap="off" value for textarea wrap attribute; is there any
>> particular reason why this is not part of HTML5?
>> Currently the only values mentioned are "soft" and "hard":
>> http://dev.w3.org/html5/spec/the-button-element.html#attr-textarea-wrap

The explanation is here.


In theory, you can achieve the same effect by using CSS.

textarea { white-space: nowrap; }

This works fine in Opera, WebKit and IE.  Doesn't work in Gecko though.

> That does seem odd. I would have thought the default value would be
> 'off' or 'no' as I've never seen a browser yet wrap text in a textarea
> unless a specific wrapping method was specified either via an attribute
> or CSS.

Netscape 4 was the last browser I'm aware of that defaulted to that 
wrap=off behaviour.  I believe every other mainstream browser I'm aware 
of since then wraps by default.

Lachlan Hunt - Opera Software
Received on Wednesday, 2 June 2010 07:10:39 UTC

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