¡@

Home 

javascript Programming Glossary: totlen

How to drag a shape along a given path

http://stackoverflow.com/questions/7406021/how-to-drag-a-shape-along-a-given-path

l e r.ellipse pt.x pt.y 4 4 .attr stroke none fill #f00 totLen p.getTotalLength start function storing original coordinates.. this.attr opacity 1 gradSearch function l0 pt l0 l0 totLen var l1 l0 dist0 dist p.getPointAtLength l0 totLen pt dist1 searchDir.. pt l0 l0 totLen var l1 l0 dist0 dist p.getPointAtLength l0 totLen pt dist1 searchDir if dist p.getPointAtLength l0 searchDl totLen..