svg - Use .tofront() with raphael -
it seems can't use .tofront() (no capital f) option in map using raphael js
the fiddle links working example, it's javascript code , bit of css3 animate path http://jsfiddle.net/6cvxf/20/
i each path goes front when click it, unfortunately piece of code doesn't work
$('path').click(function() { (this).tofront(); });
there's way better retrieve element use in click function? thanks
jquery can't access svg elements directly can use library: keith-wood.name/svg.html
mentioned here: how use jquery in svg (scalable vector graphics)?
or can simple use following built in rapahel click function achieve result seeking:
var r = raphael("canvas",500,500); var rectangle = r.rect(10, 10, 100, 100).attr({fill:'red'}).click(function(){ //click function statements this.tofront(); });
Comments
Post a Comment