Groups
Sign in
Groups
Prawn
Conversations
About
Send feedback
Help
How to set even pages to be blank
19 views
Skip to first unread message
Mitja B
unread,
Nov 7, 2018, 8:56:52 AM
11/7/18
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Prawn
I have generated a PDF with Prawn. I would like to add every second (even) blank page.
So the PDF can be printed onesided ;)
Mitja B
unread,
Nov 13, 2018, 8:06:19 AM
11/13/18
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Prawn
This is how I solve it:
# ----- add blank pages
(1..page_count).each do |p|
if go_to_page(p+(p-1))
start_new_page
end
end
Reply all
Reply to author
Forward
0 new messages