about summary refs log tree commit diff stats
path: root/edit.lua
diff options
context:
space:
mode:
Diffstat (limited to 'edit.lua')
-rw-r--r--edit.lua4
1 files changed, 2 insertions, 2 deletions
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