W3C home > Mailing lists > Public > www-style@w3.org > September 2006

Re: input element - absolute positioning - determing width with left and right

From: Anne van Kesteren <annevk@opera.com>
Date: Sat, 02 Sep 2006 11:19:39 +0100
To: Spartanicus <spartanicus.3@ntlworld.ie>, www-style@w3.org
Message-ID: <op.te8xm1ol64w2qv@id-c0020>

On Thu, 31 Aug 2006 15:20:48 +0100, Spartanicus  
<spartanicus.3@ntlworld.ie> wrote:
>> <input type="text" style="position: absolute; left: 0; right: 0;">
>> How should that be rendered?
> http://www.w3.org/TR/CSS21/conform.html#conformance
> "CSS 2.1 does not define which properties apply to form controls and
> frames, or how CSS can be used to style them. User agents may apply CSS
> properties to these elements. Authors are recommended to treat such
> support as experimental. A future level of CSS may specify this
> further."

So form controls are currently treated a bit like replaced elements, much  
like images and per the specification they should just get their intrinsic  
width for the above case. For example

   <img height="200" width="200" src="..." alt="...">

absolutely positioned with 'left' and 'right' set to zero will still get a  
width of 200px.

Anne van Kesteren
Received on Saturday, 2 September 2006 10:19:58 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:25 UTC