documentation cleanup

This fixes a lot of errors while generating the documentation with
doxygen.
documentation repaired for lib, without externals
documentation completely repaired
Merge pull request #2 from apfohl/doc-clean

Documentation cleanup, Code refactor