From 0684a20ea3da6100cf43c919d1fcfda3644eb8c1 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Wed, 12 Jun 2024 21:18:02 +0900 Subject: [PATCH] Fix invalid mouse offset for --height on Windows --- src/tui/light_windows.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tui/light_windows.go b/src/tui/light_windows.go index b7fc3402..e2a2bbfe 100644 --- a/src/tui/light_windows.go +++ b/src/tui/light_windows.go @@ -139,7 +139,7 @@ func (r *LightRenderer) findOffset() (row int, col int) { if err := windows.GetConsoleScreenBufferInfo(windows.Handle(r.outHandle), &bufferInfo); err != nil { return -1, -1 } - return int(bufferInfo.CursorPosition.X), int(bufferInfo.CursorPosition.Y) + return int(bufferInfo.CursorPosition.Y), int(bufferInfo.CursorPosition.X) } func (r *LightRenderer) getch(nonblock bool) (int, bool) {