To print directly to the printer, you have to access the device driver. I'm on linux so can't help you there. A more common method for simple files that do not have to be formatted is to write the output to a file and use os.system() or subprocess with a system call to print the file. In linux it is
os.system( "lpr filename")
In the dark ages when I used to use Windows it was just "print full_path_filename" which if it works it all the time you have to spend on this. The print command (if there is one) may also have an option to add line numbers when you print. Google should help you find more if no one here can be of more help.
woooee 814 Nearly a Posting Maven
woooee 814 Nearly a Posting Maven
AJG commented: Helpful. +1
Ene Uran commented: very nice idea +4