W3C home > Mailing lists > Public > www-svg@w3.org > November 2005

'prev' Keyword And Id Restrictions

From: Doug Schepers <doug@schepers.cc>
Date: Sun, 6 Nov 2005 19:21:40 -0500
To: <www-svg@w3.org>
Message-Id: <20051107002143.8AA88109EAA@pilfer.dreamhost.com>


When I was working on my SmilScript lib, I started wondering where the
'prev' keyword is specified. I've used it many times in my SMIL animations,
but when I actually looked for it in the W3C Recommendations [1][2][3][4], I
couldn't find it. I did find mention of it [5] in the "Synchronized
Multimedia Integration Language (SMIL) Boston Specification" (3-August-1999)
[6], but that's not just a Working Draft, not a Recommendation.

Is this actually a part of the SVG SMIL Rec, or is it an Adobe-specific
extension? Is it just something that was assumed to be in SMIL, but dropped
without anyone noticing? In any case, I would like to see it made explicit
in the new SVG1.2 Spec if it is indeed part of SVG.

I think it's a valuable keyword, but there is a problem with it. Is it
permitted to have an animation with an id="prev"? If so, how can that be
resolved with the syntax 
It's probably much too late to address this, but it really makes much more
sense (and more consistent) to have something that uses XLink syntax, like: 

The example below illustrates this problem:

<svg xmlns='http://www.w3.org/2000/svg'

   <circle id='circle_1' cx='25' cy='25' r='20' fill='gold'>
      <animateMotion to='100, 100' begin='1s' dur='2s' fill='freeze'
      <set attributeName='fill' to='blue' begin='prev.end' />

   <circle id='circle_2' cx='125' cy='25' r='20' fill='gold'>
      <animateMotion id='prev' to='100, 100' begin='1s' dur='2s'
fill='freeze' repeatCount='1'/>

   <circle id='circle_2' cx='225' cy='25' r='20' fill='gold'>
      <animateMotion id='prev1' to='100, 100' begin='1s' dur='2s'
fill='freeze' repeatCount='1'/>

   <circle id='circle_3' cx='125' cy='25' r='10' fill='red'>
      <set attributeName='fill' to='lime' begin='prev.end' />

   <circle id='circle_4' cx='225' cy='25' r='10' fill='red'>
      <set attributeName='fill' to='lime' begin='prev1.end' />

[1] http://www.w3.org/TR/SVG/animate.html (and the equivalent in SVG1.0)
[2] http://www.w3.org/TR/2001/REC-smil-animation-20010904/
[3] http://www.w3.org/TR/1998/REC-smil-19980615/
[4] http://www.w3.org/TR/2005/REC-SMIL2-20050107/smil20.html


www.vectoreal.com ...for scalable solutions.
Received on Monday, 7 November 2005 00:21:56 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:47:05 UTC