mostly cosmetic changes

reformatted the sources, changed the namings to match the conventions, etc...