You need software. PDF printing is a page-layout form - meaning that you don't just output text, you specify fonts and absolute page positions (as well as graphics and other things to make the document look nicer).
There are commercial packages for this, but a good way to get your feet wet is to get the gnujp package (formerly known as retepPDF) from
http://www.sourceforge.net I recommend that you start by writing the code in a
Java Application and capturing the output to a PDF file - that way you can debug the PDF part without getting into problems because Netscape won't display PDF's properly unless they're downloaded preceeded by a valid Content-Length header - and you won't know the PDF size until the PDF has actually been created!
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.