Skip to content

Ctrl+\ puts the current file beside the others, in a second editor group #460

Closed

Description

@a-team-app

Context

The editor area holds two editor groups side by side, each with its own tabs, so a test can sit beside the code it covers. A tab moves between groups; a file is open in at most one. Commands act on the focused group. Pitch: #60.

This waits for #451, which reworks how files open; this task changes the same open path to respect "one file, one tab".

Acceptance criteria

  • With two files open, Ctrl+\ (or mg, or View → Move to other group) moves the active tab into a new group on the right. The editor area splits its width evenly, each group with its own tab strip.
  • Ctrl+\ on a tab in the right group moves it back to the left. Moving a group's only tab out, or closing a group's last tab, closes that group and the other takes the full width.
  • mg on the only open tab, with no split, says Open another file to split with in the status bar and changes nothing.
  • F6 (or fo, or View → Focus other group) moves focus to the other group's active tab. The focused group is drawn with the focused border. Clicking in a group focuses it.
  • jg (or View → Join groups) moves every tab back into one group.
  • Opening a file that's already open in the other group, from the Explorer, Ctrl+O, a Find result, Back/Forward, or the Review tab, focuses it there instead of opening a second copy. A new file opens in the focused group.
  • In the focused group, these act on its active tab: save, close, the find bar, go to line, Ctrl+1…9, next/previous tab, change grammar, document info (di), blame (Ctrl+G B) and the Compare commands. The status bar's path, Ln, Col and selection count follow it, and so do multi-cursor carets.
  • Save all saves the dirty tabs in both groups, and quitting with unsaved changes in either group asks first.
  • Renaming, moving or deleting a file in the Explorer updates or closes its tab in whichever group holds it. A file changed on disk shows the usual notice in either group.
  • Find in files with open buffers, and Replace all, cover the tabs in both groups.
  • Back/Forward (cursor history) jumps into the group that holds the file.
  • A diff tab or the PR overview can be moved to either group like any tab.
  • Quit with a split and reopen the folder: both groups come back with their tabs, and the same group is focused. A folder last opened before this update opens as one group.
  • F1 and the command palette list Move to other group, Focus other group and Join groups with their keys.

Tests

  • Moving tabs between groups: split, move back, unsplit on emptying a group, mg with one tab and no split.
  • Focus: which group the active-tab commands reach after fo, a click, and closing the focused group.
  • One file, one tab: opening an already-open file from each entry point focuses the existing tab.
  • Save all, quit-with-unsaved, rename/move/delete, disk-change notices and global find/replace across both groups.
  • Workspace state round-trip with a split, and loading a state file from before this change.
  • Mnemonics mg, fo and jg are free and no prefix of another.

Out of scope

  • The same file in both groups, or more than two groups.
  • Stacked (top/bottom) groups, or stacking automatically at narrow widths.
  • Dragging tabs between groups, or resizing the split with the mouse.
  • Anything diff-specific.

Activity

  1. a-team-app commented on Oct 8, 2026

    @a-team-app
    ContributorAuthor

    Blocked by #451: #451 reworks how files open; this task changes the same open path so a file opens in at most one group.

  2. a-team-app commented on Oct 9, 2026

    @a-team-app
    ContributorAuthor

    Blocked by #454: Both rework how the editor's single group is used in Workbench/WorkbenchHost: #454 (PR #485) adds LanguageServers bound to Editor.Group and a new file-open path (Go to definition), which this task must route through the focused group and one-file-one-tab. Building after it merges avoids reworking both.

  3. a-team-app commented on Oct 10, 2026

    @a-team-app
    ContributorAuthor

    Draft PR #500 is up.

  4. added a commit that references this issue on Oct 10, 2026
    f3e1300
  5. added 4 commits that reference this issue on Oct 10, 2026
    3f27c5c
    6aaa4de
    f2ea711
    449cb36
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

    a-team:devClaimed by the a-team Dev

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions