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

cursor(x, y) generates wrong escape sequence #115

Closed
tukez opened this issue Mar 11, 2018 · 0 comments
Closed

cursor(x, y) generates wrong escape sequence #115

tukez opened this issue Mar 11, 2018 · 0 comments

Comments

@tukez
Copy link

tukez commented Mar 11, 2018

Escape sequence to set cursor position is CSI n ; m H.
From https://en.wikipedia.org/wiki/ANSI_escape_code

Moves the cursor to row n, column m. The values are 1-based, and default to 1 (top left corner) if omitted. A sequence such as CSI ;5H is a synonym for CSI 1;5H as well as CSI 17;H is the same as CSI 17H and CSI 17;1H

Ansi.cursor(x,y) generates "CSI< x >;< y >H", it should generate "CSI< y + 1 >;< x + 1 >H" (x,y switched and 1-based, I'm assuming Ansi.cursor(x, y) is 0-based).

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

1 participant