github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

seven1m / prawn_template_handler

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 3
    • 0
  • Source
  • Commits
  • Network (0)
  • Issues (0)
  • Downloads (0)
  • Wiki (1)
  • Graphs
  • Branch: master

click here to add a description

click here to add a homepage

  • Branches (1)
    • master ✓
  • Tags (0)
Sending Request…
Enable Donations

Pledgie Donations

Once activated, we'll place the following badge in your repository's detail box:
Pledgie_example
This service is courtesy of Pledgie.

Uber simple template handler for Prawn PDF views in Rails. — Read more

  cancel

  cancel
  • Private
  • Read-Only
  • HTTP Read-Only

This URL has Read+Write access

Updated readme, and removed gem specification. 
seven1m (author)
Wed Dec 09 05:10:17 -0800 2009
commit  a6f70e1a23ed93c9d39c6d8d411b2764e05cb2a6
tree    323dc30a6d684000430fe7457a6b0f9ca55e77d0
parent  afb16aac8cabc7a078b290b307f2aef83acd905c
prawn_template_handler /
name age
history
message
file README.markdown Loading commit data...
file init.rb
directory lib/ Fri Dec 26 09:27:06 -0800 2008 Initial import. [seven1m]
README.markdown

prawn_template_handler

This is a template handler for Prawn PDF views in Rails. Simpler than Prawnto.

Installation

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

Usage

The template registers the pdf mimetype, and the prawn template extension.

In the view file show.pdf.prawn:

pdf.move_down 200
pdf.text 'Hello World'

That's it!

If you need to specify document options, add a @pdf line to your show method, like so:

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

License

Released into the Public Domain.

Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server