W3C home > Mailing lists > Public > www-style@w3.org > May 2004

Re: 'offsetWidth/height' function

From: Dave Hyatt <hyatt@apple.com>
Date: Fri, 7 May 2004 17:35:16 -0700
Message-Id: <93B91B72-A087-11D8-BA09-000A95AE8B18@apple.com>
Cc: www-style@w3.org
To: Andrew Fedoniouk <news@terrainformatica.com>

The XUL box model actually accomplishes all that the %% units do and 
more, with less ambiguity and with the ability to specify width  and 
height values that are independent of the flexing values.  Flexing of 
an element should actually be independent of the min-width, width, and 
max-width values, so I don't think it makes sense to try to overload 
flexing onto those properties.

dave

On May 7, 2004, at 5:24 PM, Andrew Fedoniouk wrote:

>
> Hi, Dante,
>
> this is another example how easily it could be done with %% units:
>
> <div id=navbar >...</div>
> <div id=left style="display:inline-block; height:100%%; width:15em">...
> <div id=body style="display:inline-block; height:100%%; 
> width:100%%">...
> <div id=rigth style="display:inline-block; height:100%%; 
> width:20em">...
>
> Andrew Fedoniouk.
>
> Terra Informatica Software Design.
> http://terrainformatica.com
>
>
> ----- Original Message -----
> From: "Sean M. Hall" <pianoman@reno.com>
> To: <www-style@w3.org>
> Sent: Friday, May 07, 2004 3:16 PM
> Subject: 'offsetWidth/height' function
>
>
>>
>> A common problem with CSS is two column stretching. The navbar should 
>> be
> as long (no more, no less) than the content div. CSS does not yet have 
> a
> rule for this (see http://www.quirksmode.org/dom/3column.html)
>>
>> I propose this for CSS(3):
>>
>> div#navbar {
>> height: offsetHeight(div#content)px;
>> width: 25%;
>> }
>>
>> The 'px' at the end is optional.
>>
>> This may not be the best syntax, but CSS does need some sort of a 
>> rule so
> we can keep DHTML Javascript doing what it does best: enhancing 
> usability,
> not doing something CSS *should* be capable of doing.
>>
>> By the way, evolt.org is going to publish an article I wrote about 
>> CSS3
> support in modern browsers sometime in the coming weeks.
>>
>> Cheers,
>>
>> Dante
>>
>>
>>
>
Received on Friday, 7 May 2004 20:36:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:29 GMT