PDF::Writer:PDF::SimpleTable#position, #position=
require 'pdf/simpletable' pdf = PDF::Writer.new def table(pdf, position) PDF::SimpleTable.new do |tab| tab.column_order = %w(col1 col2 col3) p tab.position tab.position = position tab.show_lines = :all data = [ { "col1" => "foo", "col2" => "bar", "col3" => "baz" }, ] tab.data.replace data tab.render_on(pdf) end end [:left, :right, :center, 35, -35].each do |position| table(pdf, position) end pdf.save_as("2008041200.pdf")
で、
:center :center :center :center :center