[xforms] global attributes

Instead of leaving general attribute to the host language[1], I think 
XForms would benefit of including those attributes by default.

Attributes that would be useful to have on all elements include:

  * xml:lang
  * xml:id
  * class

(Perhaps DIR and TITLE would be useful as well, not sure.)

The problem is that the specification is currently underspecified. It is 
unclear what the host language is and what kind of CLASS attribute it 
may introduce. It is also unclear what other attributes it may introduce.

For example, while XHTML and SVG have a CLASS attribute defined as a 
space-separated list of strings, FooML might have a similar CLASS 
attribute that has a comma-separated list strings.

What if I mix XHTML, XForms and FooML? Does XForms get two CLASS attributes?

(I know of at least one implementation that has just added the CLASS 
attribute of XHTML for whatever the host language may be. I guess other 
implementations will do the same, if they consider the CLASS attribute 
to be significant enough to be supported. So if it is included as global 
attribute, it should probably be optional.)

It is also unclear whether such attributes are introduced in the 
null-namespace or not. (Well, for xml:lang it is quite clear, for CLASS 
and other undefined attributes it is not.)

So as suggested above, I think XForms should specify a set of global 
attributes rather than leaving that up to the host language. Since it is 
unclear what the host language is and it is even more unclear what 
should happen when there are multiple languages that could be the host 
language that introduce the same attribute with a different syntax, but 
similar semantic value.


[1]<http://www.w3.org/TR/xforms/slice8.html#attrs-ui-common>


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

Received on Thursday, 10 March 2005 21:38:28 UTC