1.Safer handleClose of ConsoleOutputStream, which now call underlyingTask.cancel(true);
2.Instead of update caret in event dispatch thread, simple call repaint to fix caret issue under windows.