Lots of formatting fixes