fillFreeze

by greg heil

HTML

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg id="svg2"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:xlink="http://www.w3.org/1999/xlink"
   width="400" height="500"
   version="1.1">
<text id="tup" x="48 " y="33" >up  </text>
<text id="tdn" x="235" y="33" >down</text>
 <rect id="trect" style="fill:yellow;stroke:red;"
         width="20" height="20" x="75" y="0" rx="5" ry="5" >
<animate id="tr"
   begin="tdn.mouseover"
   end="tdn.mouseout+1s"
   attributeName="x"
   additive="sum"
   fill = "freeze"
   restart = "whenNotActive"
   from=""
   to="50"
   dur="3s"
   repeatCount="1" />
  <animate id="rt"
   begin="tup.mouseover"
   end="tup.mouseout+1s"
   attributeName="x"
   additive="sum"
   fill = "freeze"
   restart = "whenNotActive"
   from=""
   to="250"
   dur="3s"
   repeatCount="1"/>
  </rect>
</svg>