Re: LC Comment - Script & Progressive Rendering / Multiple Pages

Jim,
It sounds like you don't like the language in the SVG 1.2 Last Call 
relative to when scripts are executed (http://www.w3.org/TR/SVG12/events.html):

"Script execution happens only at load time. Removing, inserting or 
altering script elements once the document has been loaded has no effect."

My guess is that you would prefer the following wording:

"Any scripting logic associated with a given <script> element is executed 
at most once. Script execution happens just after the "load" event occurs 
for the given <script> element. (Exception: if an ancestor has 
externalResourcesRequired=true, then script execution happens on the "load" 
event for that ancestor.) Removing, inserting or altering script elements 
once the document has been loaded has no effect."

Comments?

Jon

At 05:33 PM 11/30/2004, Jim Ley wrote:


>"Andrew Sledd" <Andrew.Sledd@zoomon.com> wrote in message
>news:586AE9F507AF5E4AA45364333D9E2FA201032706@sesthsrv02.zoomon.local...
>
> >Are we to infer that this means the whole document must be loaded
> >before the script is executed? Thus usefulness of combining script
> >and progressive rendering and/or multiple pages will be limited.
>
>This isn't even the current behaviour, nor the behaviour of any mark-up
>language, script is executed when the script element is parsed, I think it's
>clear this is not the case, but obviously not.
>
> >We propose that script elements when in a time container with
> > timelineBegin="onStart" should be interpreted/executed upon
> >load of the script element.
>
>No, all script elements should be executed immediately as now. (external
>scripts with externalResourcesRequired false being the one exception,
>analgous to the defer attribute in HTML)  Certainly no change to the
>existing behaviour should be considered, and changing from the behaviour of
>all other markup languages and scripts should be very much a last resort.
>
> >  <svg timelineBegin="onStart">
> >    <script> document.getElementById("foo").setTrait("visibility",
> > "visible");</script>
> >    <rect id="foo" visibility="hidden">
> >  </svg>
> >
> >Would not render the rectangle, while
>
>This should result in a script error.
>
>Jim.

Received on Wednesday, 1 December 2004 16:03:15 UTC