about summary refs log tree commit diff stats
path: root/text.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2022-06-23 12:06:44 -0700
committerKartik K. Agaram <vc@akkartik.com>2022-06-23 12:06:44 -0700
commit22330664098826620ab783f2d6f68e3639660f9e (patch)
tree3b3b645545f6aed4ef925946fa8b9d527eaaa61e /text.lua
parent84875f3c43977000d21fd10cdbcedbff22efde26 (diff)
downloadview.love-22330664098826620ab783f2d6f68e3639660f9e.tar.gz
bugfix: clear selection in a couple more places
Diffstat (limited to 'text.lua')
-rw-r--r--text.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/text.lua b/text.lua
index f37faae..24c92aa 100644
--- a/text.lua
+++ b/text.lua
@@ -296,8 +296,10 @@ function Text.keychord_pressed(chord)
     Text.word_right()
   elseif chord == 'home' then
     Cursor1.pos = 1
+    Selection1 = {}
   elseif chord == 'end' then
     Cursor1.pos = utf8.len(Lines[Cursor1.line].data) + 1
+    Selection1 = {}
   elseif chord == 'S-home' then
     if Selection1.line == nil then
       Selection1 = {line=Cursor1.line, pos=Cursor1.pos}