bugfix: update all panes on resize

akkartik
Nov 22, 2023, 5:23 AM
SFRZIHVELVPIYUO2VJRUSRSBB5PPI5JCNCT2CRZBW54WEJJPKYIAC

Dependencies

  • [2] VAVXKWZV aggregate global state inside a 'pane' object
  • [3] VEAVIL4X resize handler

Change contents

  • replacement in 0031-on.resize at line 3
    [3.84][2.698:1264]()
    Current_pane.editor_state.right = math.min(100+30*App.width('m'), Safe_width*2/3)
    Current_pane.editor_state.width = Current_pane.editor_state.right - Current_pane.editor_state.left
    Current_pane.editor_state.bottom = Safe_height/2-5
    Text.redraw_all(Current_pane.editor_state)
    Current_pane.output_editor_state.top = Current_pane.editor_state.bottom+5+10+5
    Current_pane.output_editor_state.right = Current_pane.editor_state.right
    Current_pane.output_editor_state.width = Current_pane.editor_state.width
    Current_pane.output_editor_state.bottom = Safe_height - 5
    [3.84]
    [3.246]
    for _,pane in ipairs(Panes) do
    pane.editor_state.right = math.min(100+30*App.width('m'), Safe_width*2/3)
    pane.editor_state.width = pane.editor_state.right - pane.editor_state.left
    pane.editor_state.bottom = Safe_height/2-5
    Text.redraw_all(pane.editor_state)
    pane.output_editor_state.top = pane.editor_state.bottom+5+10+5
    pane.output_editor_state.right = pane.editor_state.right
    pane.output_editor_state.width = pane.editor_state.width
    pane.output_editor_state.bottom = Safe_height - 5
    end