Major clean up. Various formatting changes.

- Fixed tabs, spacing, ordering, and other formatting for consistency.
- Fixed data encapsulation.

See differential for more specifics.