about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2022-05-20 05:44:04 -0700
committerKartik K. Agaram <vc@akkartik.com>2022-05-20 05:44:04 -0700
commitbca0c1fab97dcac2231f47ae18bd582b70775076 (patch)
tree037498ce58a66b97c5b661826ccc2223ec8cd21a
parent7fd3c92efed31a59e8e4c523f260313df348d244 (diff)
downloadlines.love-bca0c1fab97dcac2231f47ae18bd582b70775076.tar.gz
bugfix
-rw-r--r--text.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/text.lua b/text.lua
index f4181d8..b20809a 100644
--- a/text.lua
+++ b/text.lua
@@ -38,7 +38,7 @@ function Text.draw(line, line_width, line_index, cursor_line, cursor_pos)
     x = x + frag_width
     pos = pos + frag_len
   end
-  if cursor_pos == pos then
+  if line_index == cursor_line and cursor_pos == pos then
     Text.draw_cursor(x, y)
   end
   return y