Restore PDF creation

Should solve #6. Tested on my installation.