|
Draw on Chart |
Posted by patrick on May-10-2014 02:00 |
|
I tried using JavaScript canvas to allow users to draw lines on a chart.
Overall it worked fine, except when I want to export the image the only thing that exports
is the canvas.
Are there any examples of allowing a user to draw and make annotations on a chart, and if
possible export the image? |
Re: Draw on Chart |
Posted by Peter Kwan on May-13-2014 00:57 |
|
Hi Patrick,
If you are exporting the canvas as an image, it is normal that the canvas image contains
the contents of the canvas only, and not the other parts of your web page.
If you want to export the canvas as an image, so that the resulting canvas image contains
the chart image, please draw the chart image in the canvas first (eg. using the drawImage
method of the Canvas context), then you can add annotation to the canvas and export the
canvas.
Hope this can help.
Regards
Peter Kwan |
|