Skip to content
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

Track client cursor position internally #222

Closed
NuSkooler opened this issue Dec 10, 2018 · 2 comments
Closed

Track client cursor position internally #222

NuSkooler opened this issue Dec 10, 2018 · 2 comments
Milestone

Comments

@NuSkooler
Copy link
Owner

NuSkooler commented Dec 10, 2018

Issue:
Currently the system relies on ANSI DSR (Device Status Report)/CPR sequences in many areas to discover / track client cursor positions. Not limited to:

  • MCI position
  • Pause
  • Some work in the FSE

This has some major drawbacks:

  • Does not work in all terminals. Some terminals such as mTCP's telnet only partially work as their queue of DSR's is very small. Many older DOS terminals do not implement it at all.
  • Introduces a lag (essentially, we must SYN/ACK the positions).
  • May be wrong by the time we get the data, i.e.: if data scrolls (See MCI codes break for art with a height greater than term height #5)

Since we know the term dimensions, we should track the positions ourselves. This has some implications around the current implementation of Views, ansi_term.js's goto(), etc.

Also related: Some code saves/restores (SCP – Save Cursor Position / RCP – Restore Cursor Position) which may need to go as well.

@cognitivegears
Copy link
Collaborator

See my potential solution in PR #407. I'm not 100% that this won't cause any regressions yet, but if you agree I'd love to get it in and would be happy to help work through any that might (will probably) come up.

NuSkooler added a commit that referenced this issue Apr 6, 2022
@NuSkooler
Copy link
Owner Author

Big shout to @cognitivegears for the work on this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants