我用 g.Raphael 做了一个图表:
$(function(){
var r = Raphael("pieChart"),
pie = r.piechart(320, 240, 100, [55, 20, 13, 32, 5, 1, 2, 10]);
r.text(320, 100, "Interactive Pie Chart").attr({ font: "20px sans-serif" });
$(pie.sector).click(function(){
alert('hi');//not work!
})
})
后来我将click事件添加到pie.sector,但我的事件不起作用......有人知道用jQuery处理gRaphael的正确方法吗?