end
elseif State.cursor1.posB then
if State.cursor1.posB > 1 then
before = snapshot(State, State.cursor1.line)
local byte_start = utf8.offset(State.lines[State.cursor1.line].dataB, State.cursor1.posB-1)
local byte_end = utf8.offset(State.lines[State.cursor1.line].dataB, State.cursor1.posB)
if byte_start then
if byte_end then
State.lines[State.cursor1.line].dataB = string.sub(State.lines[State.cursor1.line].dataB, 1, byte_start-1)..string.sub(State.lines[State.cursor1.line].dataB, byte_end)
else
State.lines[State.cursor1.line].dataB = string.sub(State.lines[State.cursor1.line].dataB, 1, byte_start-1)
end
State.cursor1.posB = State.cursor1.posB-1
end
else
-- refuse to delete past beginning of side B