reorg
[?]
May 17, 2022, 5:54 AM
UTF73CBLAPLW2J6BUF4Q7N2TETQ2IKSUZ4267UG357V4SFXDFUTACDependencies
- [2]
7Q4B6M2Desc to cancel a shape mid-click - [3]
VVXVV2D2change data model; text can now have metadata - [4]
3CS5KKCIup/down cursor movement - [5]
OTIBCAUJlove2d scaffold - [6]
PRPPZGDYspeed up some obvious common cases - [7]
H7OEU6WPexperimental approach to combining keyboard and mouse while drawing - [8]
RJGZD4INbinary search to most natural up/down with proportional fonts - [9]
6PUNJS5Bbackspace - [10]
HWPK4SMPnew mode: manhattan - [11]
VXORMHMEdelete experimental REPL - [12]
6LJZN727handle chords - [13]
3D5RFWHVstop handling drawings in cursor_pos computations - [14]
WAZVXUV2simplest possible way to straighten strokes - [15]
IYW7X3WLleft/right cursor movement, deleting characters - [16]
3XD6M3CFrefactor
Change contents
- edit in main.lua at line 516
-- shortcuts for text - edit in main.lua at line 564
elseif chord == 'delete' thenif cursor_pos <= #lines[cursor_line].data thenlocal byte_start = utf8.offset(lines[cursor_line].data, cursor_pos)local byte_end = utf8.offset(lines[cursor_line].data, cursor_pos+1)if byte_start thenif byte_end thenlines[cursor_line].data = string.sub(lines[cursor_line].data, 1, byte_start-1)..string.sub(lines[cursor_line].data, byte_end)elselines[cursor_line].data = string.sub(lines[cursor_line].data, 1, byte_start-1)end-- no change to cursor_posendend-- transitioning between drawings and text - replacement in main.lua at line 598[4.921]→[4.1518:1550](∅→∅),[4.1518]→[4.1518:1550](∅→∅),[4.1550]→[3.2493:2692](∅→∅),[3.2692]→[4.1734:1784](∅→∅),[4.1734]→[4.1734:1784](∅→∅),[4.1784]→[3.2693:2829](∅→∅),[3.2829]→[4.1905:1918](∅→∅),[4.1905]→[4.1905:1918](∅→∅),[4.1918]→[3.2830:2919](∅→∅),[3.2919]→[4.1997:2044](∅→∅),[4.1997]→[4.1997:2044](∅→∅),[4.2044]→[4.296:314](∅→∅),[4.296]→[4.296:314](∅→∅)
elseif chord == 'delete' thenif cursor_pos <= #lines[cursor_line].data thenlocal byte_start = utf8.offset(lines[cursor_line].data, cursor_pos)local byte_end = utf8.offset(lines[cursor_line].data, cursor_pos+1)if byte_start thenif byte_end thenlines[cursor_line].data = string.sub(lines[cursor_line].data, 1, byte_start-1)..string.sub(lines[cursor_line].data, byte_end)elselines[cursor_line].data = string.sub(lines[cursor_line].data, 1, byte_start-1)end-- no change to cursor_posendend-- shortcuts for drawings