On Wed, 27 Oct 2010 22:34:02 -0500
"G. Wade Johnson" <[email protected]> wrote:

> A co-worker of mine has been experimenting with the SVG use element
> now that it is implemented more widely and reliably in browsers.
> We've been talking about SVG components that could be <use>d into an
> SVG image.
> 
> The problem he brought up has to do with script elements. Should
> script elements from a <use>d element/image be accessible from the
> main SVG?
> 
> Just as usefully, should we be able to combine some graphical elements
> and script into an SVG that gets used into another SVG as a functional
> component.
> 
> Current testing appears to say 'no'. But, I don't remember anything
> from the spec that says it shouldn't work.
> 
> Here's the page he's working with now:
> http://daveabbott.com/svg/control/0/
> 
> The script from the outer image is usable, the script from inside the
> used image is not. Is that how it should be?

I spent some time tonight digging around in the SVG 1.1 spec. As I
thought I remembered, there is no mention of the behavior of script
that is included as part of 'use'ing content. There is also no mention
of what would happen with SMIL content included in the referenced
content.

I know the spec says that the "contents of the referenced element were
deeply cloned into a separate non-exposed DOM tree" (Section 5.6).
There is an explicit comment that the referenced information is not
available to the DOM. However, the code contained in an enclosed script
tag is not part of the DOM, so there's no suggestion about whether it
should be interpreted.

Do any implementations pay any attention to child script or SMIL tags
nested within referenced content?

G. Wade
-- 
We've all heard that a million monkeys banging on a million typewriters
will eventually reproduce the works of Shakespeare. Now, thanks to the
Internet, we know this is not true.          -- Robert Wilensky, UCB


------------------------------------

-----
To unsubscribe send a message to: [email protected]
-or-
visit http://groups.yahoo.com/group/svg-developers and click "edit my 
membership"
----Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/svg-developers/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/svg-developers/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

Reply via email to