Merge upstream into main

[?]
Jul 20, 2022, 2:52 PM
73XNHEKNPTKPDNB2B6QWLRRQJ37X5AZ6FTBVL5ZBTDYP2Z2K45PQC

Dependencies

  • [2] 7CEOB56D Merge upstream into main
  • [3] UPCIYZEU drop an unnecessary level of indent
  • [4] 2RXZ3PGO beginning of a new approach to scroll+wrap
  • [5] MP2TBKU6 bugfix: crash in Text.up() after return
  • [6] EGH7XDBK support non-text lines in Text.to2
  • [7] IMEJA43L snapshot
  • [8] PNGWLAFN Merge upstream into main
  • [9] APYPFFS3 call edit rather than App callbacks in tests
  • [10] MXA3RZYK deduce left/right from state where possible
  • [11] CZB4CK2R bugfix
  • [12] NDHQN23G done passing left/right margins everywhere
  • [13] 356GY7IQ unify two similar functions
  • [14] YW2GO3U4 bugfix: crash in Text.up() after return
  • [15] LF7BWEG4 group all editor globals
  • [16] S2YQBEYC snapshot: test for a new regression
  • [17] M6TH7VSZ rip out notion of Line_width
  • [18] IWYLK45K clicking to the right of a line within line width
  • [19] QYIFOHW3 first test!
  • [20] 5DOTWNVM right margin
  • [21] HGC5RGJP switch to line index in a function
  • [22] 27DROQW2 Merge upstream into main
  • [23] PFT5Y2ZY move
  • [24] QCPXQ2E3 add state arg to a few functions
  • [25] KURLAXXI clean up some prints
  • [26] HOSPP2AN crisp font rendering
  • [27] ULKLJBN6 couple of renames
  • [28] EMHRPJ3R no, that's not right
  • [29] LXTTOB33 extract a couple of files
  • [30] 4VKEE43Z bugfix
  • [31] DGK5BPVI bugfix: UTF-8 in compute_fragments
  • [32] GL4Q5WCV keep text from overflowing right margin
  • [33] DRFE3B3Z mouse buttons are integers, not strings
  • [*] BULPIBEG beginnings of a module for the text editor

Change contents

  • replacement in text_tests.lua at line 533
    [4.981][2.2:156]()
    check_eq(Editor_state.cursor1.pos, 15, 'F - test_click_on_wrapping_line_containing_non_ascii/cursor') -- one more than the number of UTF-8 code-points
    [4.981]
    [4.2]
    check_eq(Editor_state.cursor1.pos, 15, 'F - test_click_past_end_of_wrapping_line_containing_non_ascii/cursor') -- one more than the number of UTF-8 code-points
  • edit in text_tests.lua at line 1968
    [4.43800][2.258:258](),[4.981][4.1685:1848](),[4.981][4.1685:1848]()
    check_eq(Editor_state.cursor1.pos, 15, 'F - test_click_past_end_of_wrapping_line_containing_non_ascii/cursor') -- one more than the number of UTF-8 code-points
  • resolve order conflict in text_tests.lua at line 1968
    [4.43800]
  • edit in text.lua at line 99
    [4.910][4.3:77](),[4.910][4.3:77](),[4.910][4.3:77](),[4.77][4.6:6](),[4.77][4.6:6]()
    local boffset = Text.offset(frag, bpos+1) -- byte _after_ bpos
  • edit in text.lua at line 839
    [4.360][4.837:874](),[4.360][4.837:874](),[4.874][4.22:22](),[4.874][4.22:22]()
    local offset = Text.offset(s, pos)