Fixes #63, fixes #60, fixes #59, fixes #58, fixes #57, fixes #20