sublime_merge icon indicating copy to clipboard operation
sublime_merge copied to clipboard

Ability to drag repo tabs between windows

Open plinss opened this issue 5 years ago • 5 comments

Problem description

I generally have a significant number of open repos, several sets of related repos, such as packages used by a main project. But I have other open repos that are related to each other but not the other set.

On macOS, I can merge all open windows, I can move a tab into it's own window via the menu, or I can tear off a tab into its own window by drag and drop.

I cannot however, move a tab from one window to another or merge two arbitrary windows to properly collect related repos into individual windows without closing and re-opening repos.

Preferred solution

When dragging a tab out of a window, dropping it on the tab bar of another window should move the tab to that window, rather than open a new window.

There also needs to be a way to drag a window that doesn't have tabs such that it will be added as a tab to another window (even if that window doesn't currently display a tab bar).

FWIW, in SublimeText, I can drag file tabs from one window to another. I expect to be able to do the same with repo tabs (but not file tabs within a repo).

Alternatives

Menu options to merge specific windows or move tabs to another window would also work.

plinss avatar May 29 '20 05:05 plinss

Just realized that merging windows on macOS creates an additional level of tabs for individual windows, each with tabs for repositories rather than merging windows as repository tabs of each other. Not sure if this is creating more confusion than helping.

plinss avatar May 31 '20 00:05 plinss

Hi @plinss,

Thanks for sharing this with us, and sorry to hear you're having trouble dragging tabs into Windows.

You should be able to drag a tab into the tab-bar of another window (note the tab bar must be showing). Which version of MacOS and Sublime Merge are you running?

The ability to collate tabs into one window has had some interest, so we'll be looking into this further in the future.

Thanks, - Dylan

dpjohnst avatar Jun 01 '20 00:06 dpjohnst

Hi Dylan,

just tested again and I can in fact drag a repo tab between two windows. I was probably confused initially and was dragging the window tabs rather than repo tabs. IIRC I initially selected Window>Merge All Windows and didn't realize those weren't repo tabs.

As you mentioned, though, I do have to have tab bars visible on both windows for this to work, which makes it impossible to merge two windows that only have one repo open in each, or drag the last repo out of one window into another. This best work-around I found is to create a new tab in each window to force the tab bars to be visible.

If I was dragging a tab onto a window without a tab bar, it would be nice if a tab bar popped up while hovering over it to give me a place to drop the tab. Similarly, either a control (or menu item) to show the tab bar where there's only one repo open, or some icon at the top of the window that can be used to drag that repo as a tab into another window would help. (I do appreciate not consuming the screen real estate for a tab bar with one tab under normal circumstances.)

plinss avatar Jun 01 '20 01:06 plinss

Perhaps there should be a way to temporarily force a window to show its tabs, even if there is only 1 tab.

I'll like to add on another use-case why this feature is needed. While switching between repository tabs, very often I'd accidentally drag a tab out of its window. It's frustrating not being able to drag the tab back - instead I have to close the tab, and reopen the repository again.

cardin avatar Jun 26 '20 07:06 cardin

I'll like to add on another use-case why this feature is needed. While switching between repository tabs, very often I'd accidentally drag a tab out of its window. It's frustrating not being able to drag the tab back - instead I have to close the tab, and reopen the repository again.

+1 exactly this also happens to me quite often

themilkman avatar Mar 14 '24 09:03 themilkman