Text to PDF

Turn a plain text file into a neat PDF. Your file stays on your device.

How it works

The text is set line by line with margins of 2 cm; long lines are broken at spaces to fit the page, and a form feed character starts a new page. Liberation Sans has Latin, Greek and Cyrillic letters; Courier gives every letter the same width (good for code and tables made of spaces) but only has Western letters, so a text with others is set in Liberation Sans.

The file can be UTF-8, UTF-16 or an older Windows encoding: DocTools works out which.

Made with pdf-lib 1.17.1 (MIT, as served) with fontkit 1.1.1 by Devon Govett and Andrew Dillon (MIT) and the Liberation Sans font (SIL Open Font License, as served).