refactor and fix create_pdf()
rewrite mkemptypage()
code deduplication
indent mess
refactor
refactor generate_guides()
shuffle things around
doc and version