String module was broken.

fix b1a3a3e4c6ac5b17b9d37c56f4d17198a2078eaf
Syntax cleanup
Improve the error handling, better use of ArgumentParser.
Use argparse in the pdf module.