experiment: knob for readonly editor
[?]
Jun 8, 2023, 5:16 AM
4L3UAM75XNO54CYAZ5O26L2CZMKEU25FIZNOL4RWTZSWEWENSRNQCDependencies
- [2]
6ECYOEHYbugfix: obsolete location for attribute - [3]
PV2YA7KSsubsection headings in a long switch - [4]
IM3RBHY2spurious args - [5]
TLEW46AQMerge text0 - [6]
H5UZI3YNeditor documentation - [7]
QCPXQ2E3add state arg to a few functions - [8]
4KOI3E6Rremove some redundant checks - [9]
UHB4GARJleft/right margin -> left/right coordinates - [10]
I64IPGJXavoid saving fragments in lines - [11]
LNUHQOGHstart passing in Editor_state explicitly - [12]
3MAZEQK5add state arg to Text.textinput - [13]
DHI6IJCNselecting text and deleting selections - [14]
CG3264MMmove - [15]
SPSW74Y5add state arg to Text.keychord_pressed - [16]
5ZA3BRNYadd state arg to a few functions - [17]
IFTYOERMline.y -> line_cache.starty in a few more places - [18]
2L5MEZV3experiment: new edit namespace - [19]
4EGQRXDAbugfix: naming points - [20]
X75QPYVWmove Selection1 clearing past business logic - [21]
ZHLO7K3Madd args to some functions - [22]
LF7BWEG4group all editor globals - [23]
EMHRPJ3Rno, that's not right - [24]
OGD5RAQKbugfix: naming points in drawings - [25]
HLIF3YQEMerge text0 - [26]
3HHPHDOOcouple of typos - [27]
GZ2OYPSHconfigurable colors and cursor in editor widget - [28]
MTJEVRJRadd state arg to a few functions - [29]
VJ77YABHmore efficient undo/redo - [30]
H6QZ7GRRmore precise name - [31]
PTDO2SOTadd state arg to schedule_save - [32]
VZJHGWSPMerge lines.love - [33]
2CK5QI7Wmake love event names consistent - [34]
S2MISTTMadd state arg to a few functions - [35]
HALS7E5Umore clearly skip prints before screen top - [36]
Z5HLXU4Padd state arg to a few functions - [37]
Z4XRNDTRfind text - [38]
TOKSRJMDshow how to load lines in editor - [39]
MD3W5IRAnew fork: rip out drawing support - [40]
XNFTJHC4split keyboard handling between Text and Drawing - [41]
GN3C6AGMbugfix in changing shape mid-stroke - [*]
BULPIBEGbeginnings of a module for the text editor - [*]
J2SVGR2Eexperiment: blinking cursor - [*]
X3F7ECSLadd state arg to some functions - [*]
N2NUGNN4include a brief reference enabling many useful apps
Change contents
- replacement in text.lua at line 48
elseif not hide_cursor thenelseif hide_cursor thenText.pretend_draw_cursor(State, State.left+Text.x(screen_line, State.cursor1.pos-pos+1), y)else - edit in text.lua at line 81
State.cursor_x = xState.cursor_y = y+State.line_heightendfunction Text.pretend_draw_cursor(State, x, y) - replacement in text.lua at line 148
function Text.keychord_press(State, chord)function Text.keychord_press(State, chord, readonly) - edit in text.lua at line 150
if not readonly then - edit in text.lua at line 248
endend - replacement in text.lua at line 251
elseif chord == 'left' thenif chord == 'left' then - replacement in reference.md at line 234
* `edit.keychord_press(state, chord, key)` and `edit.key_release(state, key)`* `edit.keychord_press(state, chord, key, readonly)` and `edit.key_release(state, key)` - replacement in reference.md at line 237
clipboard, undo/redo.clipboard, undo/redo. Setting `readonly` will disable mutating keystrokes. - replacement in edit.lua at line 241
function edit.text_input(State, t)function edit.text_input(State, t, readonly) - replacement in edit.lua at line 246[7.2586]→[7.10285:10292](∅→∅),[7.6749]→[7.10285:10292](∅→∅),[7.102724]→[7.10285:10292](∅→∅),[7.10285]→[7.10285:10292](∅→∅)
elseelseif not readonly then - replacement in edit.lua at line 253
function edit.keychord_press(State, chord, key)if State.selection1.line andfunction edit.keychord_press(State, chord, key, readonly)if not readonly and State.selection1.line and - replacement in edit.lua at line 302
elseif chord == 'C-z' thenelseif not readonly and chord == 'C-z' then - replacement in edit.lua at line 316
elseif chord == 'C-y' thenelseif not readonly and chord == 'C-y' then - replacement in edit.lua at line 338
elseif chord == 'C-x' thenelseif not readonly and chord == 'C-x' then - replacement in edit.lua at line 345
elseif chord == 'C-v' thenelseif not readonly and chord == 'C-v' then - replacement in edit.lua at line 368
Text.keychord_press(State, chord)Text.keychord_press(State, chord, readonly)