View
6.824
Download
2
Category
Tags:
Preview:
DESCRIPTION
This is the talk I gave at FOSDEM 2009
Citation preview
PrawnCreate PDFs with Ruby
Tom Klaasen
• Co-founder of (http://10to1.be)
• @tomklaasen
• http://tomklaasen.net
Prawn
• Prawn takes the pain out of generating beautiful printable documents, while still remaining fast, tiny and nimble.
History
• Gregory Brown: “What if I could just do open source for a while, non-commercially?”
• http://www.oreillynet.com/ruby/blog/2008/03/id_love_to_quit_my_job_sort_of.html
Goals
• The features you need, without all the complexity
• Built in support for UTF-8
• Easy image embedding
• Flexible table drawing
• Simplified content positioning
Code Examples
“Hello, World”
Render a book
Render a book (2)
Render a book (3)
• PDF: 84 pages
• “Took 6.582318 to generate.”
Tables
Tables (2)
Bounding boxes
Bounding boxes (2)
The Future
• Now: alpha
• Project is gaining traction quickly
• First stable production release: June 2009
How to get it
• gem install prawn
References
• http://prawn.majesticseacreature.com/
• http://advent2008.hackruby.com/past/2008/12/17/awn_and_the_future_of_ruby_pdf_generation
Thank You
• tom@10to1.be
• @tomklaasen
• http://tomklaasen.net
Recommended