change text cursor shape

[?]
May 20, 2022, 5:34 AM
XVR2O5PIN4KDGEIFAXR2A54Q2GDYJHXUIHRFI74UU736M4R4CLVQC

Dependencies

  • [2] H2DPLWMV snapshot: wrapping long lines at word boundaries
  • [3] BOFNXP5G clicking now moves the cursor even on long, wrapped lines
  • [4] DLQMM265 scroll past first page
  • [5] XNFTJHC4 split keyboard handling between Text and Drawing
  • [6] UWNHC4AA redo y computations
  • [7] 4C375P53 this is a bit clearer
  • [*] BULPIBEG beginnings of a module for the text editor
  • [*] OTIBCAUJ love2d scaffold

Change contents

  • replacement in text.lua at line 71
    [2.2444][2.2444:2594]()
    love.graphics.print('_', x+Text.cursor_x2(frag, cursor_pos-pos+1), y+6) -- drop the cursor down a bit to account for the increased font size
    [2.2444]
    [2.2594]
    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)
  • replacement in main.lua at line 119
    [3.1219][3.1219:1377]()
    love.graphics.setColor(0,0,0)
    love.graphics.print('_', 25, y+6) -- drop the cursor down a bit to account for the increased font size
    [3.1219]
    [3.1377]
    -- cursor
    love.graphics.setColor(1,0,0)
    love.graphics.circle('fill', 25,y+math.floor(15*Zoom), 2)