Merge lines.love

[?]
Mar 24, 2023, 4:43 AM
VOU73AK6XOVIOCY6PHUXS5RQZ2TGFEF7RYNOKFE2XSHRCZBAJMYQC

Dependencies

  • [2] JKENJ2UG Merge lines.love
  • [3] TXI6GSQD some minor cleanup
  • [4] VP5KC4XZ Merge lines.love
  • [5] VHQCNMAR several more modules
  • [6] 2CK5QI7W make love event names consistent
  • [7] ETXNVRPT Merge lines.love
  • [8] 4SR3Z4Y3 document the version of LÖVE I've been using
  • [9] T4FRZSYL delete an ancient, unused file
  • [10] BJ5X5O4A let's prevent the text cursor from ever getting on a drawing
  • [11] KKMFQDR4 editing source code from within the app
  • [12] 73OCE2MC after much struggle, a brute-force undo
  • [13] LXTTOB33 extract a couple of files
  • [14] G54H3YG2 get rid of all bifold text
  • [15] R5QXEHUI somebody stop me
  • [16] 2Y7YH7UP infrastructure for caching LÖVE text objects
  • [17] L2FWWEQL source: remember cursor position of multiple files
  • [18] ZTZOO2OQ Merge lines.love
  • [19] A4BSGS2C Merge lines.love
  • [20] RSZD5A7G forgot to add json.lua
  • [21] LNUHQOGH start passing in Editor_state explicitly
  • [22] ORKN6EOB Merge lines.love
  • [23] TLOAPLBJ add a license
  • [24] GUOQRUL7 Merge lines.love
  • [25] 4YDBYBA4 clean up memory leak experiments
  • [26] 3PSFWAIL Merge lines.love
  • [27] Q7XPSKII Merge lines.love
  • [28] D4B52CQ2 Merge lines.love
  • [29] XX7G2FFJ intermingle freehand line drawings with text
  • [30] 3QNOKBFM beginnings of a test harness
  • [31] KMSL74GA support selections in the source editor
  • [32] D2GCFTTT clean up repl functionality
  • [33] 2TQUKHBC Merge lines.love
  • [34] 2L5MEZV3 experiment: new edit namespace
  • [35] BULPIBEG beginnings of a module for the text editor
  • [36] MD3W5IRA new fork: rip out drawing support
  • [37] JOPVPUSA editing source code from within the app
  • [38] K74U4BAU Merge lines.love
  • [39] JRLBUB6L more intuitive point delete from polygons
  • [40] GFXWHTE6 mouse wheel support
  • [41] FS2ITYYH record a known issue
  • [42] VXORMHME delete experimental REPL
  • [43] 66X36NZN a little more prose describing manual_tests
  • [44] K2X6G75Z start writing some tests for drawings
  • [45] VHUNJHXB Merge lines.love
  • [46] LF7BWEG4 group all editor globals
  • [47] HRWN5V6J Devine's suggestion to try to live with just freehand
  • [48] BLWAYPKV extract a module
  • [49] OGUV4HSA remove some memory leaks from rendered fragments
  • [50] 2CTN2IEF Merge lines.love
  • [51] AVTNUQYR basic test-enabled framework
  • [52] TVCPXAAU rename
  • [53] OI4FPFIN support drawings in the source editor
  • [54] OTIBCAUJ love2d scaffold
  • [55] 6LJZN727 handle chords
  • [56] CE4LZV4T drop last couple of manual tests
  • [*] XGHCLIKB Merge lines.love

Change contents

  • file deletion: source_edit.lua (----------)source_edit.lua (----------)
    [4.2][4.165725:165764](),[4.2][4.165725:165764](),[4.165764][4.152440:152440]()
    end
    end
    function edit.mouse_wheel_move(State, dx,dy)
    if dy > 0 then
    State.cursor1 = {line=State.screen_top1.line, pos=State.screen_top1.pos}
    for i=1,math.floor(dy) do
    Text.up(State)
    end
    State.cursor1 = {line=State.screen_bottom1.line, pos=State.screen_bottom1.pos}
    for i=1,math.floor(-dy) do
    Text.down(State)
    end
    end
    elseif dy < 0 then
  • file deletion: source.lua (----------)source.lua (----------)
    [4.2][4.177652:177686](),[4.2][4.177652:177686](),[4.177686][4.165766:165766]()
    function source.mouse_wheel_move(dx,dy)
    Cursor_time = 0 -- ensure cursor is visible immediately after it moves
    if Focus == 'edit' then
    return edit.mouse_wheel_move(Editor_state, dx,dy)
    else
    return log_browser.mouse_wheel_move(Log_browser_state, dx,dy)
    end
    end
    function source.text_input(t)
  • file deletion: run.lua (----------)run.lua (----------)
    [4.2][4.184046:184077](),[4.2][4.184046:184077](),[4.184077][4.178044:178044]()
    function run.mouse_wheel_move(dx,dy)
    Cursor_time = 0 -- ensure cursor is visible immediately after it moves
    end
    function run.text_input(t)
    return edit.mouse_wheel_move(Editor_state, dx,dy)
  • file deletion: log_browser.lua (----------)log_browser.lua (----------)
    [4.2][4.203223:203262](),[4.2][4.203223:203262](),[4.203262][4.191782:191782]()
    function log_browser.down(State)
    while State.screen_top1.line < #State.lines do
    State.screen_top1.line = State.screen_top1.line+1
    if should_show(State.lines[State.screen_top1.line]) then
    break
    end
    end
    end
    function log_browser.height(State, line_index)
    local line = State.lines[line_index]
    if line.data == nil then
    -- section header
    return State.line_height
    elseif type(line.data) == 'string' then
    return State.line_height
    else
    if line.height == nil then
    --? print('nil line height! rendering off screen to calculate')
    line.height = log_render[line.data.name](line.data, State.left, App.screen.height, State.right-State.left)
    end
    return line.height
    end
    end
    end
    end
    end
    function log_browser.up(State)
    while State.screen_top1.line > 1 do
    State.screen_top1.line = State.screen_top1.line-1
    if should_show(State.lines[State.screen_top1.line]) then
    break
    end
    end
    end
    log_browser.down(State)
    elseif chord == 'pageup' then
    local y = 0
    while State.screen_top1.line > 1 and y < App.screen.height - 100 do
    State.screen_top1.line = State.screen_top1.line - 1
    if should_show(State.lines[State.screen_top1.line]) then
    y = y + log_browser.height(State, State.screen_top1.line)
    end
    end
    elseif chord == 'pagedown' then
    local y = 0
    while State.screen_top1.line < #State.lines and y < App.screen.height - 100 do
    if should_show(State.lines[State.screen_top1.line]) then
    y = y + log_browser.height(State, State.screen_top1.line)
    end
    State.screen_top1.line = State.screen_top1.line + 1
    log_browser.up(State)
    elseif chord == 'down' then
    end
    function log_browser.mouse_wheel_move(State, dx,dy)
    if dy > 0 then
    for i=1,math.floor(dy) do
    log_browser.up(State)
    end
    for i=1,math.floor(-dy) do
    log_browser.down(State)
    end
    end
    end
    elseif dy < 0 then
  • edit in source_edit.lua at line 305
    [4.25355]
    [4.21189]
    end
    end
    function edit.mouse_wheel_move(State, dx,dy)
    if dy > 0 then
    State.cursor1 = {line=State.screen_top1.line, pos=State.screen_top1.pos}
    for i=1,math.floor(dy) do
    Text.up(State)
    end
    elseif dy < 0 then
    State.cursor1 = {line=State.screen_bottom1.line, pos=State.screen_bottom1.pos}
    for i=1,math.floor(-dy) do
    Text.down(State)
    end
  • edit in source.lua at line 326
    [4.175825]
    [4.7081]
    function source.mouse_wheel_move(dx,dy)
    Cursor_time = 0 -- ensure cursor is visible immediately after it moves
    if Focus == 'edit' then
    return edit.mouse_wheel_move(Editor_state, dx,dy)
    else
    return log_browser.mouse_wheel_move(Log_browser_state, dx,dy)
    end
    end
  • edit in run.lua at line 166
    [4.183200]
    [4.7796]
    function run.mouse_wheel_move(dx,dy)
    Cursor_time = 0 -- ensure cursor is visible immediately after it moves
    return edit.mouse_wheel_move(Editor_state, dx,dy)
    end
  • resurrect zombie in main.lua at line 236
    [4.5101][4.823:894](),[4.5101][4.823:894]()
    else
    assert(false, 'unknown app "'..Current_app..'"')
    end
    end
  • resolve order conflict in main.lua at line 236
    [58.355]
    [4.823]
  • replacement in main.lua at line 241
    [4.894][4.894:925](),[4.894][4.894:925]()
    function App.wheelmoved(dx,dy)
    [4.894]
    [4.925]
    function App.mousereleased(x,y, mouse_button)
  • replacement in main.lua at line 243
    [4.956][4.956:1021](),[4.956][4.956:1021]()
    if run.mouse_wheel_move then run.mouse_wheel_move(dx,dy) end
    [4.956]
    [4.1021]
    if run.mouse_release then run.mouse_release(x,y, mouse_button) end
  • replacement in main.lua at line 245
    [4.1059][4.1059:1130](),[4.1059][4.1059:1130]()
    if source.mouse_wheel_move then source.mouse_wheel_move(dx,dy) end
    [4.1059]
    [4.191200]
    if source.mouse_release then source.mouse_release(x,y, mouse_button) end
  • replacement in main.lua at line 251
    [4.102][4.190384:190430]()
    function App.mousereleased(x,y, mouse_button)
    [4.102]
    [4.190430]
    function App.wheelmoved(dx,dy)
  • replacement in main.lua at line 253
    [4.190461][4.8324:8395]()
    if run.mouse_release then run.mouse_release(x,y, mouse_button) end
    [4.190461]
    [4.190534]
    if run.mouse_wheel_move then run.mouse_wheel_move(dx,dy) end
  • replacement in main.lua at line 255
    [4.190572][4.8396:8473]()
    if source.mouse_release then source.mouse_release(x,y, mouse_button) end
    [4.190572]
    [4.190651]
    if source.mouse_wheel_move then source.mouse_wheel_move(dx,dy) end
  • edit in log_browser.lua at line 264
    [4.8596]
    [4.200887]
    end
    function log_browser.mouse_wheel_move(State, dx,dy)
    if dy > 0 then
    for i=1,math.floor(dy) do
    log_browser.up(State)
    end
    elseif dy < 0 then
    for i=1,math.floor(-dy) do
    log_browser.down(State)
    end
    end
  • replacement in log_browser.lua at line 284
    [4.201029][4.201029:201220]()
    while State.screen_top1.line > 1 do
    State.screen_top1.line = State.screen_top1.line-1
    if should_show(State.lines[State.screen_top1.line]) then
    break
    end
    end
    [4.201029]
    [4.201220]
    log_browser.up(State)
  • replacement in log_browser.lua at line 286
    [4.201250][4.201250:201452]()
    while State.screen_top1.line < #State.lines do
    State.screen_top1.line = State.screen_top1.line+1
    if should_show(State.lines[State.screen_top1.line]) then
    break
    end
    end
    [4.201250]
    [4.201452]
    log_browser.down(State)
  • edit in log_browser.lua at line 302
    [4.202107]
    [4.202107]
    end
    end
    end
    function log_browser.up(State)
    while State.screen_top1.line > 1 do
    State.screen_top1.line = State.screen_top1.line-1
    if should_show(State.lines[State.screen_top1.line]) then
    break
  • edit in log_browser.lua at line 315
    [4.202126]
    [4.202126]
    function log_browser.down(State)
    while State.screen_top1.line < #State.lines do
    State.screen_top1.line = State.screen_top1.line+1
    if should_show(State.lines[State.screen_top1.line]) then
    break
    end
    end
    end
  • resurrect zombie in edit.lua at line 199
    [4.6276][4.1864:2073](),[4.6276][4.1864:2073](),[4.2073][3.161:182](),[4.2073][3.161:182](),[3.182][4.2080:2225](),[4.2080][4.2080:2225](),[4.2080][4.2080:2225]()
    end
    end
    function edit.mouse_wheel_move(State, dx,dy)
    if dy > 0 then
    State.cursor1 = {line=State.screen_top1.line, pos=State.screen_top1.pos}
    for i=1,math.floor(dy) do
    Text.up(State)
    end
    elseif dy < 0 then
    State.cursor1 = {line=State.screen_bottom1.line, pos=State.screen_bottom1.pos}
    for i=1,math.floor(-dy) do
    Text.down(State)
    end
  • edit in edit.lua at line 200
    [4.1870]
    [4.1870]
    --? print('selection:', State.selection1.line, State.selection1.pos)
  • edit in edit.lua at line 215
    [4.9691][4.11508:11579]()
    --? print('selection:', State.selection1.line, State.selection1.pos)