tenox7 / ttyplot

a realtime plotting utility for terminal/console with data input from stdin
Apache License 2.0
961 stars 43 forks source link

don't clear screen when exiting #41

Closed tenox7 closed 4 years ago

tenox7 commented 4 years ago

it would be nice to leave output after exiting with ^c or when there is no more data

this can be done by suing pad or newterm instead of initscr

references: https://stackoverflow.com/questions/4772061/how-do-i-use-getch-from-curses-without-clearing-the-screen https://stackoverflow.com/questions/14446311/make-curses-program-output-persist-in-terminal-scrollback-history-after-program

tenox7 commented 4 years ago

Upon more investigation turns out this is due to alternate screen in xterm-ish terminals. I have updated README.md with couple of ways to work around it. Needs more testing.

tenox7 commented 4 years ago

I have confirmed workaround from readme works on most affected terminals. As such closing the issue.