Add support for templates

* to display the pages that contain math correctly
  some templates are required
* this changes adds the option -T to include all!
  templates in the dump
* in a subsequent step those template not used by
  any of the math pages could be deleted if required
  (this is future work)