Added an 'ensure_termination' option to the 'to_file' method. Allows PDFKit to work with the latest version of wkhtmltopdf, the downside being a slower pdf generation.