From what I know either vim or emacs (I don't remember which one) provides nice code pretty-printing capabilities. Otherwise if you want your code to look professional, use LaTeX with the listings package.
http://ctan.org/tex-archive/macros/l...s/listings.pdf
BTW. It's a good idea to write the thesis itself in LaTeX too.
Bookmarks