LIKTH6HMT2XAWJX6WM2ZYUUVDLN2H6SLW42GSRNF3ZUYATSJ2LDAC IX5YTLSVVGQSTXUNGYK526DJ4YWIXO2JRBCOFCANBJJO3ZM2S7ZAC LDFXFRUOUESGMZ7Z6BCZUQFRFFRIAB67GSGN2BR2VLT2ONZPUV3QC G54H3YG2NEZPW2F6OYT5JPV7KSKVMNW5D3QT3FBCXTJHAQYTV5UAC KKMFQDR43ZWVCDRHQLWWX3FCWCFA3ZSXYOBRJNPHUQZR2XPKWULAC OI4FPFINEROK6GNDEMOBTGSPYIULCLRGGT5W3H7VLM7VFH22GMWQC 2CK5QI7WA7M4IVSACFGOJYAIDKRUTZVMMPSFWEJTUNMWTN7AX4NAC return loc1.line > #State.linesor loc1.pos > #State.lines[loc1.line].data
if loc1.line > #State.lines then return true endlocal l = State.lines[loc1.line]if l.mode ~= 'text' then return false end -- pos is irrelevant to validity for a drawing linereturn loc1.pos > #State.lines[loc1.line].data
local byte_offset = Text.offset(p.name, len-1)if len == 1 then byte_offset = 0 endp.name = string.sub(p.name, 1, byte_offset)record_undo_event(State, {before=before, after=snapshot(State, State.lines.current_drawing_index)})
if len > 0 thenlocal byte_offset = Text.offset(p.name, len-1)if len == 1 then byte_offset = 0 endp.name = string.sub(p.name, 1, byte_offset)record_undo_event(State, {before=before, after=snapshot(State, State.lines.current_drawing_index)})end