Skip to content
Myr

Use CHA for absolute horizontal cursor movement

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Related: - #4858 - https://github.com/zellij-org/zellij/issues/5370

authored by Junegunn Choi · committed by Junegunn Choi · parent 4dcedc0 · Browse files · 1 file+6 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+6 added−3 removed

  • other:+6 added−3 removed

1 file+6 added−3 removed

modified:src/tui/light.go+6 added-3 removed
254 unmodified lines
255 r.csi(fmt.Sprintf("%dB", y-r.y))256 } else if r.y > y {257 r.csi(fmt.Sprintf("%dA", r.y-y))258 }259 // Use CHA instead of CR+CUF; Zellij misplaces the next character when260 // CUF moves the cursor over cells that have not been written to yet.261 if x == 0 {259 r.stderr("\r")260 if x > 0 {261 r.csi(fmt.Sprintf("%dC", x))262 r.stderr("\r")263 } else {264 r.csi(fmt.Sprintf("%dG", x+1))265 }266 r.y = y267 r.x = x268}
1300 unmodified lines