Skip to content

Commit

Permalink
Merge pull request #21 from floydj/master
Browse files Browse the repository at this point in the history
Failing spec for issue #20
  • Loading branch information
hbrandl committed Sep 11, 2014
2 parents 4132f33 + c00bc6d commit b75bcc9
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions spec/table_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1576,4 +1576,22 @@
t.cells[2, 2].content.should == "h"
t.cells[2, 3].content.should == "i"
end

it 'illustrates issue #20', :unresolved, issue: 20 do
pdf = Prawn::Document.new
description = "one\ntwo\nthree"
bullets = description.split("\n")
bullets.each_with_index do |bullet, ndx|
rows = [[]]

if ndx < 1
rows << [ { content: "blah blah blah", colspan: 2, font_style: :bold, size: 12, padding_bottom: 1 }]
else
rows << [ { content: bullet, width: 440, padding_top: 0, align: :justify } ]
end

pdf.table(rows, header: true, width: 465, cell_style: { border_width: 0, inline_format: true })
end
pdf.render
end
end

0 comments on commit b75bcc9

Please sign in to comment.