I was struggling with the issue of a pdf.line that wasnt showing up in my prawn pdf. Some were working and some werent.

The trick is to change it use stroke_line

# Change This Line
pdf.line [20, pdf.cursor], [100, pdf.cursor]

# To This
pdf.stroke_line [20, pdf.cursor], [100, pdf.cursor]

On reason you may have tried this is because the documentation link that comes up when you Google ‘prawn’ is not up to date. Make sure your reading the latest documentation or manual for prawn.

Related External Links: