Changes from hafeez:
 print related changes
 PDF doc generation changes