Small design tweaks. More code reformating.
Fixes #5