move caching behavior inside compute_fragments

[?]
Aug 17, 2022, 11:15 PM
TXHMMX25XTR5BQLKHQXIT5TZBFW2KZ54XY3CCL36ZJYJWPKGKC6QC

Dependencies

  • [2] OYVFFWBK move
  • [3] ZDAJXYIX remove some unnecessary work
  • [4] 5DOC2CBM extract a function
  • [5] ILOA5BYF separate data structure for each line's cache data
  • [6] XUGDTYW2 stop confusingly reading a global
  • [7] X3F7ECSL add state arg to some functions
  • [8] HVJKBW5U drop some unnecessary calls
  • [9] H2DPLWMV snapshot: wrapping long lines at word boundaries
  • [*] BULPIBEG beginnings of a module for the text editor
  • [*] HGC5RGJP switch to line index in a function
  • [*] TGHAJBES use line cache for drawings as well

Change contents

  • replacement in text.lua at line 21
    [4.47][3.3:93]()
    if line_cache.fragments == nil then
    Text.compute_fragments(State, line_index)
    end
    [4.47]
    [4.3860]
    Text.compute_fragments(State, line_index)
  • replacement in text.lua at line 91
    [2.309][2.309:399]()
    if line_cache.fragments == nil then
    Text.compute_fragments(State, line_index)
    end
    [2.309]
    [2.399]
    Text.compute_fragments(State, line_index)
  • edit in text.lua at line 112
    [12.186]
    [13.54]
    if line.mode ~= 'text' then return end
  • edit in text.lua at line 114
    [13.104]
    [4.3962]
    if line_cache.fragments then
    return
    end