Re: cssom - clientTop, et v

On Sun, 09 Mar 2008 20:39:58 +0100, Garrett Smith <dhtmlkitchen@gmail.com>  
wrote:
> There is no way to get the border-right and border-bottom widths.
>
> clientTop - border-top-width
> clientLeft - border-left-width
> _______  - border-right-width?
> _______  - border-bottom-width?

True, it's not entirely clear to me what the use cases are for these. It  
made sense to add them to the specification mostly because every had them.


> The other problem with the client* properties is that they are rounded
> pixel values (at least in IE, Opera, and Safari).

All APIs in the CSSOM View Module basically give dimensions / coordinates  
in CSS pixels.


> The other problem I have is the name. "clientTop" does not describe a
> borderTopWidth.
>
> Would it make sense to:
>
> 1) include widths for ALL borders?
> 2) include floating point pixels (sub-pixels) (to avoid cumulative
> rounding issues mentioned in earlier msg)
> 3) renames these properties to something non-conflicting so as to
> avoid compatibility issues with (2)?

Given that there's already getComputedStyle and the CSSOM tries to  
introduce Element.currentStyle I don't think any of these is needed.


-- 
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>

Received on Sunday, 9 March 2008 20:10:55 UTC