VSCodeVim / VSCodeVim/Vim

Individual Pane History

Open
#6,459 4 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
15.2k
Forks
1.5k
Avg merge
3d 18h
Merged PRs (30d)
6

Description

When multiple panes are displayed on the screen, the history of the cursor isn't contained within each pane but is instead contained in a "global"-like history.

I mainly work in zen-mode, but have confirmed that this is also present outside of that state.


To Reproduce

  1. Open up two files that are each split into their own pane (vertically or horizontally, it doesn't matter)
  2. On one of the panes (Pane 1), navigate to a completely different file from the first two
  3. Focus on the other pane (Pane 2), and press Ctrl-o to go back to the previous cursor position

Expected Behaviour
The cursor shouldn't move, since the only interaction that Pane 2 has had was the loading of a file into the buffer.

Current
The file in Pane 1 gets loaded into Pane 2 and the cursor is placed at the position equal to that of the cursor in the file in Pane 2 (more than likely the top left).


The main problem with this (which is exacerbated in zen-mode) is that the context that is created with each pane is lost, given the files end up switching between panes. Thus resulting in a lot of mental context-switching which I was trying to avoid in the first place by using panes.


Environment

  • VsCodeVim version: 1.19.3
  • VSCode Version: 1.56.0-insider (but also verified this happens not on the regular release version)
  • OS: Windows 10

(this was definitely a fine line between bug and feature request, but bug seemed sensible)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with two split panes, including in zen-mode, and start by tracing the Ctrl-o history behavior. Compare the cursor history created in each pane and verify whether navigation in Pane 1 affects Pane 2. Done means each pane preserves its own history and Ctrl-o no longer loads Pane 1's file into Pane 2.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
developer-experience, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.