Another big round of changes.

Things seem to be working pretty well at this point. I'm sure I'll keep
piddling though.