Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Allow (optional) prev/next change navigation within visible page in Text Diff #717

Closed
@goran-w

Description

Enhancement/suggestion #616 was closed after implementing a version which is different from my suggested implementation in PR #703. This was done with a reasoning that change navigation within the currently visible "page" is unnecessary (which is where I beg to differ).

The currently implemented feature (on develop branch, not yet released) is basically an enhanced Page Up/Down, which jumps to the previous/next "page" that contains a change not already shown on the current "page". No highlighting is made, since there is no notion of a "current" change.

In contrast, my PR adds the following features which are more similar to how P4Merge, WinMerge and other external Diff/Merge tools do their change navigation:

  • Jump (scroll) to prev/next change-block (defined as a consecutive block of added/removed lines).
  • Highlight the "current change-block".
  • Show numbers for "current change-block" and "total number of change-blocks" in the Diff toolbar. (Example: 3/15)
  • For each new Diff, the "current change-block" is initially unset (Example: -/15) and no highlighting is done until a prev/next arrow is clicked.
  • Prev/next arrows are not disabled when at first/last change-block, instead clicking the arrow in these cases will scroll the first/last change-block into view again.

I would like this alternative implementation (from the PR) to be included as an optional feature, selectable by an option in Preferences. The current implementation could still be the default for this option. (See ongoing discussion in the PR.)

NOTE: Keyboard shortcuts could be added as a future enhancement.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /