22UKX65B6LPWOULTG44ZI6YOWSNKSQSHGFJ37O2UH7YJNDL2UD4QC
local line = State.cursor1.line
local max = #State.lines
for _ = 1, max-1 do
line = (line+1) % max
if State.lines[line].mode == 'text' then
State.cursor1.line = line
State.cursor1.pos = 1
break
end
end
end
function edit.put_cursor_on_next_loc_wrapping_around_if_necessary(State)
local cursor_line = State.lines[State.cursor1.line].data
if State.cursor1.pos <= utf8.len(cursor_line) then
State.cursor1.pos = State.cursor1.pos + 1
else