javascript - ChartJS and jsPDF - why the background is black? -


i generating pdf file using jspdf library. okay, @ page chart has white background ( on pdf - black ):

chart webpage: enter image description here

and pdf: enter image description here

my code generating file:

var newcanvas = document.queryselector('#canvaschart');     var newcanvasimg = newcanvas.todataurl("image/jpeg", 1.0);     var doc = new jspdf('landscape');     doc.setfontsize(20);     doc.text(15, 15, "super cool chart");     doc.addimage(newcanvasimg, 'jpeg', 10, 10, 280, 150 );     doc.save('new-canvas.pdf'); 

do have idea how solve ? in advance,


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -