Class RGhost::Convert
In: convert.rb
Parent: Object

Convert PDF file to another format using commom render parameters of the Engine A additional parameter for this method is :range. Below someone examples:

Only cover page"/dir/myfile.pdf").to :jpeg, :filename => "/tmp/test.jpg"

One page per file

It‘s generate file with pattern test_0001.png, test_0002.png, etc"/dir/myfile.pdf").to :png, :multipage => true, :filename => "/tmp/test.png"

One page per file with page range"/dir/myfile.pdf").to :eps,  :multipage => true, :filename => "/tmp/test.eps", :range => 1..5

Getting files after convertion"/dir/myfile.pdf").to :eps,  :multipage => true, :filename => "/tmp/test.eps", :range => 1..5
 files.class # => Array because parameter multipage is true"/dir/myfile.pdf").to :eps, :filename => "/tmp/test.eps"
 file.class # => File


new   to  


error  [R] 
errors  [R] 

Public Class methods

Public Instance methods