I am creating some geometrical figures on my web pages, for which I am using RaphaelJS. Currently, I have some animated circles.
I want to add pie shapes to my web page as well, and the trickier thing about which I don’t known how to go about is adding content inside those pie shapes. How do I add the pie on my web page, inside which I can place content such as text, images etc. (or for that matter other html elements as well)
Using RaphaelJS, you can create text like this:
You are going to want to pass the x,y position as a variable that is relative to your pie slice. Here is some example code for pie charts: raphaeljs.com/pie.html.
Also, I found this tutorial that looks pretty good: http://net.tutsplus.com/tutorials/javascript-ajax/an-introduction-to-the-raphael-js-library/