The Great Documentation Update®

Put all docstrings where they belong (I've been coding python for years,
you think I would remember how docstrings are supposed to work, but
alas, I digress).

Also add some comments and notes to various functions. Document a few
undocumented functions too.

This commit brought to you by vim, >, V, and d/p. :)