public
Description: Uber simple template handler for Prawn PDF views in Rails.
Homepage:
Clone URL: git://github.com/seven1m/prawn_template_handler.git
name age message
file README.markdown Fri Dec 26 19:55:16 -0800 2008 Don't forge rake gems:install. [seven1m]
file init.rb Fri Dec 26 09:27:06 -0800 2008 Initial import. [seven1m]
directory lib/ Fri Dec 26 09:27:06 -0800 2008 Initial import. [seven1m]
file prawn_template_handler.gemspec Fri Dec 26 19:42:20 -0800 2008 Update gemspec [seven1m]
README.markdown

PrawnTemplateHandler

Uber simple template handler for Prawn PDF views.

Installation

Add the following to your environment.rb Initializer block:

config.gem 'seven1m-prawn_template_handler', :source => 'http://gems.github.com', :lib => 'prawn_template_handler'

Then run "sudo rake gems:install" to install as a dependency.

Or, use the traditional plugin install method:

script/plugin install git://github.com/seven1m/prawn_template_handler.git

Usage

In show.pdf.prawn:

pdf.move_down 200
pdf.text 'Hello World'

If you need to specify document options, add a @pdf line to your show method (optional):

def show
  @pdf = Prawn::Document.new(:page_layout => :landscape)
end

License

Released into the Public Domain.