From 3df002f4af93502ff2ee77e329e81e1e8439c321 Mon Sep 17 00:00:00 2001 From: payonel Date: Wed, 8 Jun 2022 06:57:57 -0700 Subject: [PATCH] #3499 edit fix: floor cursor positions passed to setCursor. note that this could be done in tty but trying to reduce impact of this change --- src/main/resources/assets/opencomputers/loot/openos/bin/edit.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/resources/assets/opencomputers/loot/openos/bin/edit.lua b/src/main/resources/assets/opencomputers/loot/openos/bin/edit.lua index 8ee9b2a34..ff731845b 100644 --- a/src/main/resources/assets/opencomputers/loot/openos/bin/edit.lua +++ b/src/main/resources/assets/opencomputers/loot/openos/bin/edit.lua @@ -202,6 +202,7 @@ end local function setCursor(nbx, nby) local x, y, w, h = getArea() + nbx, nby = nbx // 1, nby // 1 nby = math.max(1, math.min(#buffer, nby)) local ncy = nby - scrollY