#974·hunk

idea: move the current line with g, G, u, d and follow it with the view

Author: reobinCreated Sep 2, 2026Updated Sep 2, 2026

What do you want to change?

Today g, G, u and d scroll the view first, then the current-line marker jumps to the edge of the view.

Proposed: these four keys move the current line, and the view follows.

  • g: line to the first row, view to the top
  • G: line to the last row, view to the bottom
  • d: line down half a screen, view follows; u is the reverse

j/k already work this way. The rest of the motions like mouse wheel, scrollbar, and page keys (space, b, f) don't change. They stay scroll first, cursor follows.

Why?

  • The marker does not end up where you looked. After d, it is dragged to the top edge of the view, with no context around it.
  • The keys can feel unresponsive. Press d until the view reaches the bottom of the stream: the marker sits at the top edge, and pressing G changes nothing on screen, because the marker only follows the view.
  • Editors like vim do it this way: the cursor moves, and the view follows.

Version: 0.20.1