From 4d1e7f922db04e1d57d5604ec604b974c922cbf8 Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Sun, 14 Aug 2022 07:56:12 -0700 Subject: bugfix: obsolete location for attribute --- edit.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'edit.lua') diff --git a/edit.lua b/edit.lua index 7006da8..efc6f71 100644 --- a/edit.lua +++ b/edit.lua @@ -352,7 +352,7 @@ function edit.keychord_pressed(State, chord, key) edit.update_font_settings(State, 20) Text.redraw_all(State) elseif chord == 'C-z' then - for _,line in ipairs(State.lines) do line.starty = nil end -- just in case we scroll + for _,line_cache in ipairs(State.line_cache) do line_cache.starty = nil end -- just in case we scroll local event = undo_event(State) if event then local src = event.before @@ -396,7 +396,7 @@ function edit.keychord_pressed(State, chord, key) end schedule_save(State) elseif chord == 'C-v' then - for _,line in ipairs(State.lines) do line.starty = nil end -- just in case we scroll + for _,line_cache in ipairs(State.line_cache) do line_cache.starty = nil end -- just in case we scroll -- We don't have a good sense of when to scroll, so we'll be conservative -- and sometimes scroll when we didn't quite need to. local before_line = State.cursor1.line -- cgit 1.4.1-2-gfad0