Fixes #5, Fixes #6, Fixes #3, Fixes #2, Fixes #7, Fixes #8