diff options
| author | Eli Zaretskii | 2026-02-22 12:39:12 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2026-02-22 12:39:12 +0200 |
| commit | 81168edb1075a88ec0a3be27abedf8bcbbfa7c78 (patch) | |
| tree | f03658d8d61789e438af25cc5239feded2b71ed3 | |
| parent | 923aac2e4ec76b51891ba711c44ee08f7211ea2a (diff) | |
| download | emacs-81168edb1075a88ec0a3be27abedf8bcbbfa7c78.tar.gz emacs-81168edb1075a88ec0a3be27abedf8bcbbfa7c78.zip | |
Fix absolute cursor positioning in term.el
* lisp/term.el (term-handle-ansi-escape): Cursor Character
Absolute uses one-based column numbers; adjust to Emacs's
zero-based column numbering. (Bug#80458)
| -rw-r--r-- | lisp/term.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/term.el b/lisp/term.el index 9ac77730350..15ba310a73a 100644 --- a/lisp/term.el +++ b/lisp/term.el | |||
| @@ -3698,7 +3698,7 @@ color is unset in the terminal state." | |||
| 3698 | (term-move-columns (- (max 1 (car params))))) | 3698 | (term-move-columns (- (max 1 (car params))))) |
| 3699 | ;; \E[G - cursor motion to absolute column (terminfo: hpa) | 3699 | ;; \E[G - cursor motion to absolute column (terminfo: hpa) |
| 3700 | ((eq char ?G) | 3700 | ((eq char ?G) |
| 3701 | (term-move-columns (- (max 0 (min term-width (car params))) | 3701 | (term-move-columns (- (max 0 (1- (min term-width (car params)))) |
| 3702 | (term-current-column)))) | 3702 | (term-current-column)))) |
| 3703 | ;; \E[J - clear to end of screen (terminfo: ed, clear) | 3703 | ;; \E[J - clear to end of screen (terminfo: ed, clear) |
| 3704 | ((eq char ?J) | 3704 | ((eq char ?J) |