Cleanse tabs and spaces and add documentation