save auto-scroll state
limited scrollback
clean up all handles, solving 100%-CPU-on-window-close bug