configurable colors and cursor in editor widget
[?]
Dec 1, 2022, 3:31 AM
GZ2OYPSHZU3FNO5HYP53EABOLM4C3TFPB5RGTIW2CJAWT6D2QXYQCDependencies
- [2]
H6QZ7GRRmore precise name - [3]
BE3WIEVKupdate cursor in search box - [4]
Y4SPXCM3bugfix: pagedown was sometimes bouncing up - [5]
HNZMFBMQMerge lines.love - [6]
PP2IIHL6stop putting button state in a global - [7]
LWPRYDLWset color for each fragment - [8]
LAW2O3NWextract variable Margin_left - [9]
ILOA5BYFseparate data structure for each line's cache data - [10]
IWYLK45Kclicking to the right of a line within line width - [11]
MD3W5IRAnew fork: rip out drawing support - [12]
J2SVGR2Eexperiment: blinking cursor - [13]
3PSFWAILMerge lines.love - [14]
ZLJGZYQGselect text with shift + mouseclick - [15]
VG75U7IMbugfix: typing should delete highlighted text - [16]
MSOQI3A5bugfix: check before cursor on same line - [17]
5DOC2CBMextract a function - [18]
2JLVAYHBstart decoupling editor tests from App - [19]
X3F7ECSLadd state arg to some functions - [20]
NZKYPBSKcheck for scroll when just typing - [21]
V3EABA35skip multiple consecutive whitespace - [22]
XNFTJHC4split keyboard handling between Text and Drawing - [23]
QKAMUWSBanother bugfix in scrolling while inserting text - [24]
WAR3HXHTtest both ways of selecting text with mouse - [25]
3ZSUBI57drop some redundant args from Text.draw - [26]
Z4XRNDTRfind text - [27]
7EQLPB3Obugfix: don't delete selection when moving cursor - [28]
62JEPVQ3bugfix: backspace from start of final line - [29]
AMOPICKVbugfix: check after cursor on same line when searching upwards - [30]
TXHMMX25move caching behavior inside compute_fragments - [31]
B3IWYWSRdelete another arg that can be deduced - [32]
LXTTOB33extract a couple of files - [33]
CVSRHMJ2experiment: slightly adaptive scrolling - [34]
Y2ZIPXEMnew test - [35]
GJLOKCYKbugfix: clicking past end of screen line - [36]
HPVT467Winitialize contains test state - [37]
RMKMPFT5fix a corner case when selecting text - [38]
T3B4NLV3include a unit test - [39]
YJJ4X4JGbugfix: avoid scrolling on 'end' - [40]
4WAFGF4Zselection bugfix - [41]
S2YQBEYCsnapshot: test for a new regression - [42]
UH4YWHW5button framework is at the app level - [43]
OYXDYPGSget rid of debug variables - [44]
2L5MEZV3experiment: new edit namespace - [45]
WJBZZQE4fold together two largely similar cases - [46]
KOTI3MFGbugfix in previous commit - [47]
EKKFWP4Dbugfix: couple of margin-relative computations - [48]
ERQKFTPVextract method - [49]
EETIR4GXbugfix: skip over drawings when searching - [50]
5STHSG4Uremove some duplication - [51]
2Y7YH7UPinfrastructure for caching LÖVE text objects - [52]
2CTN2IEFMerge lines.love - [53]
CVGE3SIGI feel confident now that page-down is working. - [54]
LF7BWEG4group all editor globals - [55]
4KC7I3E2make colors easier to edit - [56]
EWMPYCDObugfix - [57]
4J2L6JMRbugfix: deleting a selection spanning pages - [58]
WLJCIXYMadd state arg to a few functions - [59]
MUJTM6REbring back a level of wrapping - [60]
BULPIBEGbeginnings of a module for the text editor - [61]
Y36LOGR5bugfix: show cursor when past end of line - [62]
2RXZ3PGObeginning of a new approach to scroll+wrap - [63]
HTWAM4NZbugfix: scrolling in left/right movements - [64]
2LC3BM2Nsupport other whitespace chars in word movements - [65]
KWOJ6XHEcut/copy selected text to clipboard - [66]
LNUHQOGHstart passing in Editor_state explicitly - [67]
5BMR5HRTclick to the left of a line - [68]
VSBSWTE4bugfix: where cursor is drawn - [69]
FZBXBUFFbugfix: search - [70]
M6TH7VSZrip out notion of Line_width - [71]
XUGDTYW2stop confusingly reading a global - [72]
TGHAJBESuse line cache for drawings as well - [73]
H2DPLWMVsnapshot: wrapping long lines at word boundaries - [74]
BW2IUB3Kkeep all text cache writes inside text.lua - [75]
CIQN2MDEbugfix: typing a capital letter deletes selection - [76]
ELJNEPW2simplify cursor-on-screen check - [77]
ZDAJXYIXremove some unnecessary work - [78]
356GY7IQunify two similar functions - [79]
IFTYOERMline.y -> line_cache.starty in a few more places - [80]
LLAOOMULbugfix: search upwards - [81]
NUZFHX6Iflesh out some tests for word movements - [82]
4VKEE43Zbugfix - [83]
UHB4GARJleft/right margin -> left/right coordinates - [84]
32V6ZHQBMerge lines.love - [85]
EMHRPJ3Rno, that's not right - [86]
KMRJOSLYbugfix: delete selection before pasting - [87]
H3ECRBXFbugfix: clicking on empty lines - [88]
DSLD74DKlots more tests - [89]
APYPFFS3call edit rather than App callbacks in tests - [90]
3TFEAQSWstart using some globals - [91]
5UKUADTWdistinguish consistently between mouse buttons and other buttons - [92]
HALS7E5Umore clearly skip prints before screen top - [93]
KURLAXXIclean up some prints - [94]
36Z442IVback to commit 8123959e52f without code editing - [95]
CNCYMM6Amake test initializations a little more obvious - [96]
UD7HNQL7purge unused button infrastructure
Change contents
- replacement in text_tests.lua at line 9
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 39
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 65
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 77
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 89
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 102
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 115
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 127
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 139
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 151
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 163
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 175
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 188
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 200
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 212
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 224
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 236
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 253
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 271
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 291
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 310
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 325
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 343
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 361
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 381
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 401
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 419
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 438
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 458
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 482
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 504
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 529
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 555
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 575
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 599
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 618
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 636
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 659
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 678
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 697
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 717
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 742
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 762
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 810
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 841
edit.draw(Editor_state) -- populate line_cache.starty for each line Editor_state.line_cacheedit.draw(Editor_state, Text_color) -- populate line_cache.starty for each line Editor_state.line_cache - replacement in text_tests.lua at line 859
edit.draw(Editor_state) -- populate line_cache.starty for each line Editor_state.line_cacheedit.draw(Editor_state, Text_color) -- populate line_cache.starty for each line Editor_state.line_cache - replacement in text_tests.lua at line 880
edit.draw(Editor_state) -- populate line_cache.starty for each line Editor_state.line_cacheedit.draw(Editor_state, Text_color) -- populate line_cache.starty for each line Editor_state.line_cache - replacement in text_tests.lua at line 906
edit.draw(Editor_state) -- populate line_cache.starty for each line Editor_state.line_cacheedit.draw(Editor_state, Text_color) -- populate line_cache.starty for each line Editor_state.line_cache - replacement in text_tests.lua at line 937
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 954
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 979
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1010
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1039
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1056
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1086
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1115
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1145
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1174
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1209
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1239
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1268
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1297
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1328
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1357
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1382
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1412
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1440
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1470
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1494
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1514
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1547
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1577
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1608
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1638
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1668
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1703
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1732
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1875
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1950
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 1972
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 2000
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 2019
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text_tests.lua at line 2038
edit.draw(Editor_state)edit.draw(Editor_state, Text_color) - replacement in text.lua at line 11
function Text.draw(State, line_index, y, startpos)function Text.draw(State, line_index, y, startpos, fg, hide_cursor) - replacement in text.lua at line 22
App.color(Text_color)App.color(fg) - replacement in text.lua at line 52
App.color(Text_color)App.color(fg) - replacement in text.lua at line 55
elseText.draw_cursor(State, x+Text.x(frag, State.cursor1.pos-pos+1), y)elseif not hide_cursor thenText.draw_cursor(State, x+Text.x(frag, State.cursor1.pos-pos+1), y, Cursor_color, fg) - replacement in text.lua at line 64
if State.search_term == nil thenif not hide_cursor and State.search_term == nil then - replacement in text.lua at line 66
Text.draw_cursor(State, x, y)Text.draw_cursor(State, x, y, Cursor_color, fg) - replacement in text.lua at line 72
function Text.draw_cursor(State, x, y)function Text.draw_cursor(State, x, y, cursor_color, reset_color) - replacement in text.lua at line 75
App.color(Cursor_color)App.color(cursor_color) - replacement in text.lua at line 77
App.color(Text_color)App.color(reset_color) - replacement in text.lua at line 901
App.draw()edit.draw(State, --[[should be drawn over]] Cursor_color) - replacement in search.lua at line 19
Text.draw_cursor(State, 25+App.width(State.search_text),y-5)Text.draw_cursor(State, 25+App.width(State.search_text),y-5, Cursor_color, Text_color) - replacement in edit.lua at line 54
-- cursor coordinates in pixels-- cursor coordinates in pixels (nil => no cursor drawn in viewport) - replacement in edit.lua at line 82[8.366]→[8.2701:2727](∅→∅),[8.3868]→[8.2701:2727](∅→∅),[6.44]→[8.999:1023](∅→∅),[8.2727]→[8.999:1023](∅→∅),[8.3913]→[8.999:1023](∅→∅)
function edit.draw(State)App.color(Text_color)function edit.draw(State, fg, hide_cursor) - replacement in edit.lua at line 102
y, State.screen_bottom1.pos = Text.draw(State, line_index, y, startpos)y, State.screen_bottom1.pos = Text.draw(State, line_index, y, startpos, fg, hide_cursor) - replacement in edit.lua at line 108
Text.draw_search_bar(State)Text.draw_search_bar(State, hide_cursor) - replacement in edit.lua at line 324
love.graphics.setFont(love.graphics.newFont(Editor_state.font_height))love.graphics.setFont(love.graphics.newFont(State.font_height)) - replacement in edit.lua at line 354
edit.draw(State)edit.draw(State, Text_color) - replacement in edit.lua at line 362
edit.draw(State)edit.draw(State, Text_color) - replacement in edit.lua at line 371
edit.draw(State)edit.draw(State, Text_color) - replacement in edit.lua at line 378
edit.draw(State)edit.draw(State, Text_color) - replacement in edit.lua at line 385
edit.draw(State)edit.draw(State, Text_color)