about summary refs log tree commit diff stats
path: root/text.lua
diff options
context:
space:
mode:
Diffstat (limited to 'text.lua')
-rw-r--r--text.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/text.lua b/text.lua
index fec980b..d3998f9 100644
--- a/text.lua
+++ b/text.lua
@@ -693,7 +693,8 @@ function Text.snap_cursor_to_bottom_of_screen(State)
   Text.redraw_all(State)  -- if we're scrolling, reclaim all fragments to avoid memory leaks
 end
 
-function Text.in_line(State, line, x,y)
+function Text.in_line(State, line_index, x,y)
+  local line = State.lines[line_index]
   if line.starty == nil then return false end  -- outside current page
   if x < State.left then return false end
   if y < line.starty then return false end
href='#n120'>120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147