Merge upstream into main
[?]
Jul 1, 2022, 6:46 PM
OEUU62GMV5NDJTICRKJSGKG3TO5DJIPY6CQZNNP53MK737X3KG6QCDependencies
- [2]
IPW5MN2QMerge upstream into main - [3]
PNGWLAFNMerge upstream into main - [4]
VUVH2XLFMerge upstream into main - [5]
XI5OALQXsome redundant calls - [6]
YIQYNVD2rip out the line-width slider - [7]
7M7LS7I2start saving some settings to disk on quit - [8]
YGCT2D2Ostart loading settings as applicable - [9]
5DOTWNVMright margin - [10]
WOXIYUTLbugfix: manage screen_top and cursor when resizing - [11]
NZ7V4BVSnote card - [12]
7M5PGWKUdrop last couple of manual tests - [13]
HJ3PM2VT. - [14]
YW2GO3U4bugfix: crash in Text.up() after return - [15]
IWYLK45Kclicking to the right of a line within line width - [16]
OTIBCAUJlove2d scaffold - [17]
ZNLTRNNKhighlight another global - [18]
CCYSVZA2bugfix: BSOD in #4. - [19]
RMKMPFT5fix a corner case when selecting text - [20]
FYS7TCDWbugfix - [21]
MYC7XR5Qbugfix: lines that aren't drawn from the start - [22]
EQP53UQVautosave slightly less aggressively - [23]
J5IEBT64enforce press/release state only processed once - [24]
HYEAFRZ2split mouse_pressed events between Text and Drawing - [25]
EDY3RQULgracefully handle a non-existent filename at the commandline - [26]
EMHRPJ3Rno, that's not right - [27]
M6TH7VSZrip out notion of Line_width - [28]
QU7NHFOVshow cursor - [29]
7XKWT5Y5correct location of the line width slider - [30]
K464QQR4more defensive resize handling - [31]
W7JMT5V2rip out most support for polygons - [32]
23DEB6JLmake sure to save right when quitting - [33]
RF5ALVNYallow the window to be resized - [34]
7IKRRESBlonger names for indices in long loops - [35]
HOSPP2ANcrisp font rendering - [36]
NFCBIEZDaffordance to adjust width for word wrap - [37]
AVQ5MC5Dfinish uppercasing all globals - [38]
4VKEE43Zbugfix - [39]
PX7DDEMOautosave slightly less aggressively - [40]
DDXXXXBRnew mode for polygons - [41]
27DROQW2Merge upstream into main - [42]
OYXDYPGSget rid of debug variables - [43]
DHCLUDCW. - [44]
HDC3AAQPsilly reason my screenshots had an ugly black line down the left - [45]
KVHUFUFVreorg - [46]
MGOQ5XAVstart uppercasing globals - [47]
VIU2FBNVmake sure to save right when quitting - [48]
AM42E4Y6avoid redundant writes on exit - [49]
CPZGQT72go through and fix similar issues - [50]
42LVB4DEtest: naming a point - [51]
DGK5BPVIbugfix: UTF-8 in compute_fragments - [52]
KAUD3YIKtests: deleting points/shapes - [53]
BATTU6HWstop blanking screen while resizing - [54]
4NDYV4WDfix 2 bugs in line selection - [55]
CZB4CK2Rbugfix - [56]
IRV65LZPfold variables for screen dimensions into the app framework - [57]
6J3NXBYGaffordance to adjust width for word wrap - [58]
2C7CTIQYmake space for multiple kinds of width - [59]
DLQMM265scroll past first page - [60]
OAHNWDYG. - [61]
U76D4P36fix a typo - [62]
2INHXC3Kposition cursor by clicking on text - [63]
AD34IX2Zcouple more tests - [64]
AVTNUQYRbasic test-enabled framework - [65]
5FW7YOFThighlight selection while dragging - [66]
MP2TBKU6bugfix: crash in Text.up() after return - [67]
XX7G2FFJintermingle freehand line drawings with text - [68]
WDMPH4ANdrop support for squares - [69]
CRYGI3LRmore drawing tests - [70]
ZUOL7X6Vmove - [71]
73OCE2MCafter much struggle, a brute-force undo - [72]
OWK3U6VDtests for drawing polygons - [73]
BOFNXP5Gclicking now moves the cursor even on long, wrapped lines - [74]
5L7K4GBDclicking to the right of a wrapped line - [75]
J2SVGR2Eexperiment: blinking cursor - [*]
LXTTOB33extract a couple of files - [*]
BULPIBEGbeginnings of a module for the text editor - [*]
JRLBUB6Lmore intuitive point delete from polygons - [*]
K2X6G75Zstart writing some tests for drawings - [*]
7DYUAOI6test: undo moving point
Change contents
- edit in text_tests.lua at line 263
App.screen.init{width=200, height=80} - resurrect zombie in text_tests.lua at line 264
-- 0 1 2-- 123456789012345678901Lines = load_array{'the quick brown fox jumped over the lazy dog'} - edit in text_tests.lua at line 267
Line_width = 160 - resurrect zombie in text_tests.lua at line 267
Margin_right = 0; Margin_width = Margin_left - resurrect zombie in text_tests.lua at line 268
Cursor1 = {line=1, pos=1}Screen_top1 = {line=1, pos=1}Screen_bottom1 = {}App.draw()local y = Margin_topApp.screen.check(y, 'the quick brown fox ', 'F - test_click_past_end_of_word_wrapping_line/baseline/screen:1')y = y + Line_height - edit in text_tests.lua at line 275[11.676]→[11.676:741](∅→∅),[11.676]→[11.676:741](∅→∅),[11.741]→[11.741:754](∅→∅),[11.741]→[11.741:754](∅→∅),[11.741]→[11.741:754](∅→∅),[11.754]→[11.754:803](∅→∅),[11.754]→[11.754:803](∅→∅),[11.754]→[11.754:803](∅→∅)
-- click past the end of the screen line but within Line_widthApp.draw()App.run_after_mouse_click(Line_width-2,y-2, 1) - resurrect zombie in text_tests.lua at line 277[11.301]→[11.803:927](∅→∅),[11.803]→[11.803:927](∅→∅),[11.803]→[11.803:927](∅→∅),[11.803]→[11.803:927](∅→∅)
-- cursor moves to end of screen linecheck_eq(Cursor1.pos, 20, 'F - test_click_past_end_of_word_wrapping_line/cursor') - edit in text.lua at line 676
local screen_line_starting_byte_offset = Text.offset(line.data, screen_line_starting_pos) - edit in main_tests.lua at line 68[4.1865]→[4.1865:1870](∅→∅),[4.1870]→[11.552:751](∅→∅),[11.552]→[11.552:751](∅→∅),[11.751]→[11.77:153](∅→∅),[11.153]→[11.851:1120](∅→∅),[11.851]→[11.851:1120](∅→∅)
endfunction test_adjust_line_width()io.write('\ntest_adjust_line_width')Filename = 'foo'App.screen.init{width=Margin_left+300, height=300}Line_width = 256App.draw() -- initialize buttonApp.run_after_mouse_press(256, Margin_top-3, 1)App.mouse_move(200, 37)-- no change for some timeApp.wait_fake_time(0.01)App.update(0)check_eq(Line_width, 256, 'F - test_adjust_line_width/early')-- after 0.1s the change takesApp.wait_fake_time(0.1)App.update(0)check_eq(Line_width, 200, 'F - test_adjust_line_width') - edit in main.lua at line 106
-- line-width indicatorLine_width_hover = nil - edit in main.lua at line 195
Last_resize_time = App.getTime() - resurrect zombie in main.lua at line 195
Selection1 = {} -- no support for shift drag while we're resizingText.tweak_screen_top_and_cursor() - edit in main.lua at line 197
Last_resize_time = App.getTime() - edit in main.lua at line 231
- edit in main.lua at line 232
- resolve order conflict in main.lua at line 232
- edit in main.lua at line 315
-- make sure to save before quitting - edit in main.lua at line 316
- resurrect zombie in main.lua at line 316
-- make sure to save before quitting - resolve order conflict in main.lua at line 316
- edit in main.lua at line 320
-- save some important settingslocal x,y,displayindex = love.window.getPosition()local settings = {x=x, y=y, displayindex=displayindex,width=App.screen.width, height=App.screen.height,font_height=Font_height, filename=Filename, screen_top=Screen_top1, cursor=Cursor1}love.filesystem.write('config', json.encode(settings)) - edit in main.lua at line 334
-- we seem to sometimes get phantom clicks if the mouse moves down into text while adjusting line-widthif Line_width_hover thenSelection1 = {}returnend - edit in main.lua at line 350
--? print('selection') - edit in main.lua at line 569
-- save some important settingslocal x,y,displayindex = love.window.getPosition()local settings = {x=x, y=y, displayindex=displayindex,width=App.screen.width, height=App.screen.height,font_height=Font_height, filename=Filename, screen_top=Screen_top1, cursor=Cursor1}love.filesystem.write('config', json.encode(settings)) - resolve order conflict in main.lua at line 569[79.331]
- replacement in drawing_tests.lua at line 196
App.screen.init{width=Margin_left+300, height=300}App.screen.init{width=Margin_width+256, height=300} -- drawing coordinates 1:1 with pixels - edit in drawing_tests.lua at line 198
Line_width = Margin_left+256 -- drawing coordinates 1:1 with pixels - edit in drawing_tests.lua at line 469
App.screen.init{width=Margin_width+256, height=300} -- drawing coordinates 1:1 with pixels - edit in drawing_tests.lua at line 600[11.4357]→[9.6190:6284](∅→∅),[11.4357]→[9.6190:6284](∅→∅),[11.7265]→[9.5525:5619](∅→∅),[11.7265]→[9.5525:5619](∅→∅),[11.847]→[9.5240:5334](∅→∅),[11.847]→[9.5240:5334](∅→∅)
App.screen.init{width=Margin_width+256, height=300} -- drawing coordinates 1:1 with pixelsApp.screen.init{width=Margin_width+256, height=300} -- drawing coordinates 1:1 with pixelsApp.screen.init{width=Margin_width+256, height=300} -- drawing coordinates 1:1 with pixels - resolve order conflict in drawing_tests.lua at line 600[81.2215]