This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
Printing text from file
Prints the text file using the predefined tag :pre
Example
doc=RGhost::Document.new :paper => :A4, :landscape => true
doc.print_file "/etc/passwd"
doc.render :pdf, :filename => "/tmp/passwd.pdf
or
doc=Document.new :paper => :A4, :landscape => true
File.readlines("/etc/passwd").each {|line| doc.show_next_row(line) }
doc.render :pdf, :filename => "/tmp/passwd.pdf
Another way
doc=Document.new :paper => :A4, :landscape => true
doc.text File.readlines.join('<br/>')
doc.render :pdf, :filename => "/tmp/passwd.pdf






