JPTest: Polish up main window and fix several minor bugs