Implemented @kenda's pull request...

And I also did LOTS of cleaning in the code, fixed lots of messed up tab
styles and spaces, trailing white spaces etc.