Re: Exposing the critical ACTUAL style values?

Shelby Moore wrote:

>Ray,
>
>Regarding your assertion that the W3C DOM is pure markup and contains no
>presentation state, I think there are many examples in existing W3C DOM
>standards where this is violated.  For example, look at the HTMLSelectElement:
>
>http://www.w3.org/TR/2002/PR-DOM-Level-2-HTML-20021108/html.html#ID-94282980
>
>The selectedIndex, value, options, blur, and focus function both as read
>properties of the current presentation state as well as the  markup.
>
>I think that resoundly blows a hole in the abstract idea that the DOM can't
>have presentation interfaces.  Thus is a precedent for 1:1 correlation
>between markup and presentation.  I think it is logically consistent that
>the DOM can represent both the markup state and thru extended interfaces
>also return the current transformed state.
>  
>
In the HTML DOM, there are certain presentation properties exposed 
directly on objects.

Please define "transformed state" before I can tell you whether I agree 
with you or not.

The more specific the DOM APIs for dealing only with a specific markup 
language, the less problem there is defining where 1:1 correspondances 
are likely to always exist.  The HTML DOM is almost always used to 
present in a legacy-browser-type fashion, and hence in the HTML DOM, we 
know much more about the likely presentation than in the core or XML DOM 
modules.

Of course even the HTML Working Group at W3C does not like the present 
HTML DOM long-term because they wish to make the HTML browser more 
flexible with less built-in knowledge about the markup language, 
especially when moving to the modularity envisioned for XHTML.

>Again I do not think specialized interfaces for modifying the transformed
>state are to be encouraged.  Where ever possible it is logically very
>important that one try to use markup to set state.
>
Again, please define "the transformed state".  I don't believe it has 
ever been defined before, so it is hard to determine which layer you are 
targetting and whether it is standard enough to be exposed.

If it includes focus state, blur, current form field values, etc. then I 
disagree.

If it is the actual computed style values, as obtained via the CSS 
module, then I agree, which is why you are permitted through that module 
to modify, not the end result, but the upstream result, if memory serves me.

Ray Whitmer
rayw@netscape.com

Received on Wednesday, 18 December 2002 19:34:48 UTC