Skip to content

Page-scroll the diff pane while the file tree has focus (page-sized J/K) #357

Closed

Description

@codemageddon

J/K scroll the diff viewport from either pane (#220), but only by a few lines.
PgDown/PgUp and Ctrl+d/Ctrl+u stay pane-relative: with the tree focused they
page the tree, not the diff. To skim a file page by page I still have to Tab into
the diff and back.

lazygit binds <pgup>/<pgdown> (alts <c-u>/<c-d>) to scroll-main, so paging
works from any side panel.

Proposal

Add page-sized versions of the existing actions — e.g. scroll_diff_page_down /
scroll_diff_page_up (plus half-page) — handled in handleTreeAction next to
ActionScrollDiffDown/Up, scrolling by viewport height and honouring
--page-overlap.

That alone lets users get lazygit behaviour with
map pgdown scroll_diff_page_down. Whether PgDown/PgUp should point at the new
actions by default, and whether the tree then keeps its own paging, is your call —
I'd be fine with remap-only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions