-
Notifications
You must be signed in to change notification settings - Fork 82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how=2 also clear the entire display #399
base: master
Are you sure you want to change the base?
Conversation
It is working as intended.
|
Who is right? xtermjs, or windows terminal, msys terminal and other tools? |
vt510 doesn't have the concept of scrollback history. We should unleast reference xterm. Of course, Windows terminal may have evolved differently as xterm and inconsistency is expected. Terminus would follow xterm's standard in case of having any inconsistency. |
By the way, it also depends on the |
Options from clear
If -x tries to not clear scrollback, what does not calling it with -x supposed to do according to clear? it prints:
So 3 is there, why does terminus stops at 2? Calling it with -x prints
So you may be right, however, terminus stopping at 2 and not handling 3, wich is present, is a bug right? |
|
I am using Windows, in cmd to clear the entire cmd I have to use "cls" instead of "clear". |
That's because printf("\014"); // ^L
return 0; Neither Windows Terminal nor |
0 = clear display from cursor to end, therefore it needs history
however
2 = clear entire display
On windows when using git bash,
clear
didn't clear the entire display, it put back the history therefore you could always scroll backIf you use the provided terminal emulator (from msys), calling
clear
clear the entire display, so that's the proper behavior, same when using Windows TerminalWith this PR
clear
now behaves properly with TerminusFix #120, #340 and probable some other issues
There is also this line in the code base that looks suspicious:
https://github.com/randy3k/Terminus/pull/399/files#diff-1ff8d95a5f63ac2d193b501633246f1211a04d98c4ef04782ddd5a9a1dc327b3R390-R392