Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Join tab to window #2407

Open
rahidelvi opened this issue Jan 23, 2017 · 18 comments
Open

Join tab to window #2407

rahidelvi opened this issue Jan 23, 2017 · 18 comments

Comments

@rahidelvi
Copy link

W allows us to move a tab to a new window. Is there a key combination where I can do the reverse? That is, can I join a tab to another open window?

There's a Chrome extension called Tab Glue that does it, however, I was hoping this might be possible with vimium.

@smblott-github
Copy link
Collaborator

There's no such command currently.

@windo
Copy link

windo commented Apr 8, 2017

Would we need a way to name and/or number windows before adding such a command? I suppose vimium could probably map window ID to an index consistently. So something like moveTabToWindow? At that point, we would also need a goToWindow to be able to effectively manage tabs and windows together.

I'd like this as well - I tend to grow a large number of tabs and occasionally would like to organize them into collections based on tab type (ie: documents/articles I'd like to read) or task (investigating foo, planning vacation). As it stands, it is often too much to eagerly create new windows when starting a new task but once you have 5 tabs open for a task, it's inconvenient to create a new window and move the tabs over too.

Would goToWindow and moveTabToWindow that operate with window "indices" (and current tab for the move) sound like OK commands to implement?

@windo
Copy link

windo commented Apr 23, 2017

I tried working on this and experimented a bit with organizing tabs between windows. The main question is indeed how to identify and target windows once you have more than two. It was somewhat convenient to move tabs between two windows with just two commands: moveTabToFirstWindow and moveTabToLastWindow.

But once you move past 2 windows the UX becomes trickier. I think there are basically two options:

  1. Display list of target windows on Vomnibar
  2. Rather than targetting windows directly, allow moving tabs to "next" and "previous" window

For (1) it is also not clear how to identify the windows even on Vomnibar. By the title of the currently selected tab? By listing all tabs, that is "moveTabToWindowThatHasTheTabYouSelectOnVomnibar"?

For (2) I'm not sure how to handle moving a count of tabs. You wouldn't want to have to keep typing the count (of tabs - although arguably maybe the count should then refer to number of windows back/forward to move a single tab?) when rotating them through windows. Wouldn't want to keep typing 3wn, 3wn, 3wn etc to move 3 tabs through a few windows.

@windo
Copy link

windo commented Apr 23, 2017

Or maybe:

  1. yankTabToMove and moveYankedTabsHere

@windo
Copy link

windo commented Apr 23, 2017

This is what I'm currently trying:

https://github.com/philc/vimium/compare/master...windo:moveToWindow?expand=1

yT to yank some tabs for moving and then p in a new window to move them.

Also R to move some tabs to the last tab move target window used, useful for "repeating" the last tab move for more tabs. Not so sure about this one yet but some sort of single command variant would be helpful when reorganizing many tabs and windows.

@smblott-github
Copy link
Collaborator

Great enthusiasm, @windo, but slow up a bit.

Of your ideas above, I like 2 the best.

To me, it's an open question whether we need a whole new command for this. This feature is asked for occasionally, but not a whole lot.

Might there not be a way to implement it as a command option on the moveTabLeft/Right or moveTabToNewWindow? We already have a few commands whose behaviour can be tweaked via options, https://github.com/philc/vimium/wiki/Tips-and-Tricks#custom-key-mappings-with-a-count.

@windo
Copy link

windo commented Apr 23, 2017

moveTabToNewWindow (currently) always creates a new window and lacks a direction option - it sounds confusing to add direction=left/right and new_window=false options to it.

For moveTabLeft/Right is your proposal to add a 'move_window=true' option to them that rather than moving the tab left in a window would move it to the previous (by some standard) window? That sounds needlessly confusing to me as well.

So I think we need at the very least a new moveTabToWindow command of some sort.

As for the UX, I'll try out different options for a while to see how they work out for my use cases and report back. Will be sure to experiment with (2) as well since that's the one you prefer.

@codeanpeace
Copy link

codeanpeace commented Mar 24, 2019

Thoughts on one of these workflows?

Append tab to target window:

  1. pressing a new shortcut to moveTabToTargetWindow
  2. pop up the Vomnibar tab selection window listing the active tab of each window in a format similar to Vomnibar.activateTabSelection
  3. select a window to append the current tab to

Move tab next to target tab:

  1. pressing a new shortcut to moveTabAfterTargetTab/moveTabBeforeTargetTab
  2. pop up the Vomnibar tab selection window similar to Vomnibar.activateTabSelection
  3. select a tab to move the current tab next to

@kovasap
Copy link

kovasap commented Apr 3, 2019

I'm very interesting in seeing any way to move tabs between windows implemented!

@gdh1995
Copy link
Contributor

gdh1995 commented Apr 4, 2019

In my customized Vimium (named Vimium C - https://github.com/gdh1995/vimium-c), there's a command of moveTabToNextWindow, and it moves the current tab window by window - a little naive, but at least works. If you like you may have a try.

It also has moveTabToIncognito to re-open a tab in a incognito window, and joinTabs to move all tabs into a current window.

@markschwarz
Copy link

If this was available in vimium I'd use it! Is a merge to this repo possible?

@codeanpeace
Copy link

Hoping this gets implemented sometime, but in the meantime I'll be trying out this chrome extension Tabbo I just found that looks promising.

@d3adb5
Copy link

d3adb5 commented Jan 13, 2022

Has this been implemented already and someone forgot to close the issue, or am I just very late to the party in expressing my interest in this?

Currently I rely on the mouse to move tabs across windows. Took me a while to learn there were commands to move tabs up and down on the tab list, and they're now happily mapped to < and >, but moving things across windows would be nice.

Sometimes I want to switch to a page already in a tab, but present in another window, in another workspace. It would be neat to have a T that "pulls" tabs not in the current window into the current window. That would suffice to me, really.

@fanurs
Copy link

fanurs commented Feb 20, 2022

Just a daily user of vimium, here to express my interest in having this feature! 😎

@gliptak
Copy link

gliptak commented Nov 8, 2022

#3925

@valentingregoire
Copy link

Wasavi has it as well, it's a very similar extension. I really miss this feature with Vimium.

@eggbean
Copy link

eggbean commented May 17, 2023

I'm using this extension as a stop-gap. I have set Shift-Alt-m to activate it to move the current tab to the next window. Do it again for the next window after that. It cycles back to the original window. Multiple tabs which can be shift/ctrl-click selected with the mouse can also be moved.

@S1lander
Copy link

In my customized Vimium (named Vimium C - https://github.com/gdh1995/vimium-c), there's a command of moveTabToNextWindow, and it moves the current tab window by window - a little naive, but at least works. If you like you may have a try.

It also has moveTabToIncognito to re-open a tab in a incognito window, and joinTabs to move all tabs into a current window.

This is the best solution imo. Just use vimium C, it has so many good features that are missing in vimium.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests