delete drawing using backspace
I solemnly swear that I am aware of the risk of data loss..
This commit is contained in:
parent
4158eee7f6
commit
8a6d3ce799
2
main.lua
2
main.lua
|
@ -471,6 +471,8 @@ function keychord_pressed(chord)
|
|||
elseif chord == 'backspace' then
|
||||
if #lines > 1 and lines[#lines] == '' then
|
||||
table.remove(lines)
|
||||
elseif type(lines[#lines]) == 'table' then
|
||||
table.remove(lines) -- we'll add undo soon
|
||||
else
|
||||
local byteoffset = utf8.offset(lines[#lines], -1)
|
||||
if byteoffset then
|
||||
|
|
Loading…
Reference in New Issue
Block a user