JsPDF
Generate PDF files in client-side JavaScript.
I've exposed jsPDF to C2 users, you can find more info here
Let's you create multiple pdfs with different sizes and orientations containing multiple pages. Please test if it's possible on multiple platforms and send feedback. Initial test are ok on Chrome, Firefox and Node-Webkit .
After feedback from the forum users and hopefully some improvements, i'll push this to Git for everybody to use .
API
Actions
Set Font Size (size)
Add text (X,Y,Angle,String)
Add Image (X,Y,width,height,DataUri Type, DataUri string )
Draw a line (x1,y1,x2,y2)
Draw a rectangle (X,Y,width,height, style)
Draw an ellipse (X,Y,rx,ry,style)
Set text font (font name, font size)
Save pdf (filename)
Add page
Set properties (title,subject,author,keywords,creator)
Set text color (r,g,b)
Set stroke color (r,g,b)
Set fill color (r,g,b)
New (orientation, unit, format)
Expressions
Pdf as DataURL
plugin
html test
pdf_test.capx
Changelog 03.07.2014:
Upped plugin version to 1.1
Updated jsPDF libray to 1.0.178
Added support for PNG, JPG and JPEG DataURI types,
Two new formats available; d1, credit-card
Changelog 13.07.2014:
Upped plugin version to 1.2
Draw ellipse implemented
Set text colour implemented
Set fill colour implemented
Set stroke colour implemented
Added style parameter when drawing objects (Valid styles include: 'S' [default] - stroke, 'F' - fill, and 'DF' (or 'FD') - fill then stroke)
Changelog 05.1.2014:
Minification support thanks to —
Plugin is now available on the repo (search for the "download zip" to download plugin)