Sha256: 494255d2c71f4f050cd812db14c7c08356633aa8699d415e33eb98302bf54a00

Contents?: true

Size: 655 Bytes

Versions: 10

Compression:

Stored size: 655 Bytes

Contents

# encoding: utf-8

$LOAD_PATH << File.join(File.dirname(__FILE__), '..', 'lib')
require "prawn"
 
pdf = Prawn::Document.new   
pdf.line_width = 10    

[[100,741,100,641], 
 [100,691,150,691],
 [150,741,150,641],
 [200,741,200,641],   
 [100,600,100,500],
 [100,600,150,550],
 [100,550,150,550],
 [175,600,175,500], 
 [175,600,225,550], 
 [175,550,225,550],
 [175,550,225,500],
 [275,600,250,500],
 [275,600,300,500],   
 [250,550,300,550],
 [315,600,350,500],
 [350,500,365,550], 
 [365,550,380,500],
 [380,500,415,600], 
 [430,600,430,500],
 [430,600,465,500],
 [465,600,465,500]].each { |points| pdf.stroke_line(*points) }

pdf.render_file "lines.pdf"

Version data entries

10 entries across 10 versions & 4 rubygems

Version Path
fullcirclegroup-fullcirclegroup-prawn-0.2.99.2 examples/line.rb
fullcirclegroup-prawn-0.2.99.3 examples/line.rb
satoko-prawn-0.2.99.6 examples/line.rb
prawn-0.1.0 examples/line.rb
prawn-0.1.1 examples/line.rb
prawn-0.1.2 examples/line.rb
prawn-0.2.2 examples/line.rb
prawn-0.2.1 examples/line.rb
prawn-0.2.0 examples/line.rb
prawn-0.2.3 examples/line.rb