codestyle fix

I added doc-blocks, removed unused imports, empty lines, added file headers etc.
@WouterJ, @rande have a look and see if we all agree about the standards.