extract a function

[?]
May 20, 2022, 12:40 PM
5DOC2CBMBDMAOJ7IKLDGVRCY4SNPCJTTF7DK7WGNLPGNV4AWVJNAC

Dependencies

  • [2] RTDYYP4H bugfix: text past cursor was rendered red on wrapped lines
  • [3] BOFNXP5G clicking now moves the cursor even on long, wrapped lines
  • [4] DLQMM265 scroll past first page
  • [5] Y36LOGR5 bugfix: show cursor when past end of line
  • [6] XVR2O5PI change text cursor shape
  • [7] H2DPLWMV snapshot: wrapping long lines at word boundaries
  • [8] UWNHC4AA redo y computations
  • [9] XNFTJHC4 split keyboard handling between Text and Drawing
  • [*] BULPIBEG beginnings of a module for the text editor
  • [*] OTIBCAUJ love2d scaffold

Change contents

  • replacement in text.lua at line 35
    [3.2426][3.2426:2444](),[3.2444][3.1:143](),[3.143][2.1:39]()
    -- cursor
    love.graphics.setColor(1,0,0)
    love.graphics.circle('fill', x+Text.cursor_x2(frag, cursor_pos-pos+1),y+math.floor(15*Zoom), 2)
    love.graphics.setColor(0,0,0)
    [3.2426]
    [3.2594]
    Text.draw_cursor(x+Text.cursor_x2(frag, cursor_pos-pos+1), y)
  • replacement in text.lua at line 42
    [3.29][3.29:138](),[3.138][2.40:74]()
    -- cursor
    love.graphics.setColor(1,0,0)
    love.graphics.circle('fill', x,y+math.floor(15*Zoom), 2)
    love.graphics.setColor(0,0,0)
    [3.29]
    [3.138]
    Text.draw_cursor(x, y)
  • edit in text.lua at line 50
    [3.2796]
    [3.41]
    function Text.draw_cursor(x, y)
    love.graphics.setColor(1,0,0)
    love.graphics.circle('fill', x,y+math.floor(15*Zoom), 2)
    love.graphics.setColor(0,0,0)
    end
  • replacement in main.lua at line 119
    [3.1219][3.146:280](),[3.280][2.77:119]()
    -- cursor
    love.graphics.setColor(1,0,0)
    love.graphics.circle('fill', 25,y+math.floor(15*Zoom), 2)
    love.graphics.setColor(0,0,0)
    [3.1219]
    [3.1377]
    Text.draw_cursor(25, y)