- From: L. David Baron <dbaron@dbaron.org>
- Date: Sat, 12 Jul 2008 14:44:42 -0700
- To: www-style@w3.org
On Saturday 2008-07-12 15:26 +0200, Francois Remy wrote: > // Return the inline element style > readonly attribute CSSStyleDeclaration style; > // Return the JScript style (obsolete?) > readonly attribute CSSStyleDeclaration runtimeStyle; > // Return all rules that are finally applied to the element > readonly attribute CSSStyleDeclaration currentStyle; > // Return the style that's finally applied on the element > readonly attribute CSSStyleDeclaration computedStyle; I'm not sure I follow exactly what you'd want in runtimeStyle or currentStyle (or what the difference is). However, I'd note that there may be value in two different forms of specified style: * a CSSStyleDeclaration that has all properties specified in author style sheets * a CSSStyleDeclaration that has all properties specified at all levels of the cascade I think the first of these would be preferable for editing-type tasks (manipulating markup intended to be used later). The second would be a little more like getComputedStyle. In both cases, it would have no value for properties that aren't specified. (This is different from computed style, which always has a value.) (Something else that might be interesting, although I'm not sure if it would be particularly useful for Web authors, is a way of getting all the author style rules that match an element. The DOM Inspector extension to Firefox shows this information; I'm not sure if it would be useful from script.) -David -- L. David Baron http://dbaron.org/ Mozilla Corporation http://www.mozilla.com/
Received on Saturday, 12 July 2008 21:45:17 UTC