Question: I have a string with the text precisely spaced the way I want it displayed. It's sort of an ascii art project. I want to convert this text to a pdf so I can print a poster with the text at my local printshop.

The font needs to be fixed width and there are no tabs or anything like that. The lines end in the '\n' character. There are several space characters.

The image is several hundred characters wide and several hundred high. So, it doesn't fit in the space of a typical page.

How do I do this in python?

Answer: 
Try the module [pyPdf](http://pybrary.net/pyPdf/), might do the trick for you!

Or [pyfPdf](http://code.google.com/p/pyfpdf/), that allows you to set the font when you create new PDF-files ([setFont example](http://code.google.com/p/pyfpdf/wiki/SetFont))

From [pyfPdf Tutorial Page](https://code.google.com/p/pyfpdf/wiki/Tutorial) :

```
from fpdf import FPDF

pdf=FPDF()
pdf.add_page()
pdf.set_font('Courier','B',16)
pdf.cell(40,10,'Hello World!')
pdf.output('tuto1.pdf','F')

```
Try [report lab](http://www.reportlab.com/software/opensource/rl-toolkit/)
It has some cool features like

1. Supports embedded Type-1 or TTF fonts
2. Supports Asian, Hebrew and Arabic characters
3. Supports bitmap images in any popular format
4. Supports vector graphics