Re: Proposal: getStyleAs(property, primitiveValue)

On Wed, 23 Sep 2009 23:02:54 +0200, Garrett Smith <dhtmlkitchen@gmail.com>  
wrote:

> How does a program obtain a reference to an "abstract view" besides
> document.defaultView?

The assumption seems to be that the global object implements AbstractView,  
otherwise, how would 'document' give a reference to an implementation of  
DocumentView?

> The DOM 2 spec does not say that there is a global function
> "getComputedStyle". Why rely on it?

Well, I can't find any place where it says that there is a global  
"document" either.

>>> A corresponding method to set a value would not seem to be necessary,
>>> as any value could be set with:
>>>
>>> x.style.color = "papayawhip";
>>
>> Well, not if there's an !important color declaration somewhere that  
>> affects
>> x.
>
> OK. What are you getting at?

Just pointing out that it doesn't always work, nothing more.

-- 
Øyvind Stenhaug
Core Norway, Opera Software ASA

Received on Thursday, 24 September 2009 09:02:18 UTC