problems with SVG example in XForms PR

Hello,

There are a few problems with G.3 Survey Using XForms and SVG
in the XForms PR: http://www.w3.org/TR/xforms/sliceG.html#id2645436.

Firstly, it references an out of date SVG specification.
The DOCTYPE should be SVG 1.1.

<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" 
         "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">

Of course, you comment out the DOCTYPE anyway, since it doesn't
make sense for this example.

Secondly, while you have an SVG example you don't reference
the SVG specification (normatively or non-normatively). You
may want to add a reference to:
http://www.w3.org/TR/SVG11 (Note SVG 1.1, not 1.0)

Thirdly, you use the SVG <foreignObject> element without
providing a fallback for UAs that don't support XForms.
Here is what the SVG 1.1 specification has to say about this
(4th/last paragraph at: http://www.w3.org/TR/SVG11/extend.html#EmbeddingForeignObjects):

"Usually, a 'foreignObject' will be used in conjunction with the
'switch' element and the requiredExtensions attribute to provide
proper checking for user agent support and provide an alternate
rendering in case user agent support is not available."

You also set properties 'font-size' and 'font-family' on the 
<foreignObject> element, with the (probably valid) assumpution that
the style processing will work across the namespace boundary. Unfortunately,
there is no W3C rules for this, so it isn't really guaranteed to
work.

We like the fact that there is an example, but are still a little
worried that XForms would go to REC with something that may
not work. So, we suggest the addition of some introductory text,
something like:

"The following example shows one possible way of integrating XForms
with SVG. Note that the complete set of rules for integrating XForms
and SVG are not fully specified at the time this specification was
published. Future versions of the XForms and/or SVG (or other W3C)
specifications might define more complete rules for integrating XForms
and SVG which may or may not be compatible with the example below.

Note that the example below does not use SVG's <switch> and
'requiredExtensions' features, which are commonly used in conjunction
with <foreignObject>."

Dean, for SVG WG.

Received on Wednesday, 27 August 2003 01:18:18 UTC