Fixes #248 and various ui issues
Fixes #252