bspwm icon indicating copy to clipboard operation
bspwm copied to clipboard

i3 Style Tabs

Open InvalidWaldo opened this issue 7 years ago • 24 comments

I don't know about others, but the only thing stopping me from switching to BSPWM full time, is the i3 style tabs.

While this is not an actual "issue" but a feature request. How difficult would it be to implement i3 style tabs into BSPWM?

InvalidWaldo avatar May 24 '19 17:05 InvalidWaldo

Pretty sure bspwm limits itself to being just a window manager and only that. Many of the features that you have on other wm you have to manually craft here. You can probably do it with query and implement somewhere but why. If you want fanciness stick with i3 or even go for awesome.

cadr10 avatar Aug 12 '19 03:08 cadr10

An alternative to tabs is to use the monocle layout and rofi to switch between windows.

Rofi includes, out of the box, a mode for selecting windows of the current desktop:

rofi -modi windowcd -show windowcd

Then you can use ctrl + n, ctrl + p or tab to select the window.

mdutra avatar Aug 14 '19 17:08 mdutra

I wrote this a year or two ago which does pretty much what i3 stacks do, though it does it by resizing the windows. https://github.com/thezoq2/bspwmstackablewindows

TheZoq2 avatar Sep 29 '19 15:09 TheZoq2

@TheZoq2 Can you do a video on it?

alexherbo2 avatar Sep 29 '19 16:09 alexherbo2

There is one, it's a bit hidden, but check the demo link in the readme

-------- Original Message -------- On 29 Sep 2019, 18:12, Alex Leferry 2> wrote:

@TheZoq2 Can you do a video on it?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

TheZoq2 avatar Sep 29 '19 16:09 TheZoq2

The link is broken. I figured it out in the raw README.

https://gfycat.com/ScentedBackCrustacean

alexherbo2 avatar Sep 29 '19 20:09 alexherbo2

Pretty sure bspwm limits itself to being just a window manager and only that. Many of the features that you have on other wm you have to manually craft here. You can probably do it with query and implement somewhere but why. If you want fanciness stick with i3 or even go for awesome.

@cadr10 Surprisingly enough, that's pretty unhelpful 😮. Do you get paid commission to throw people at competing projects that do not even seem to try to fulfill similar objectives or do you just take pleasure in random gatekeeping?

Either way, thanks @TheZoq2 looks like an interesting way of doing it, and seems to solve the problem at hand 😄

InvalidWaldo avatar Sep 30 '19 07:09 InvalidWaldo

There is ways around to hack, but i3 tab style is not possible in bspwm by nature. For arranging windows, bspwm uses a binary tree (a container is limited to 2 windows), while i3 uses an n-ary tree (the number of windows in a container is not limited).

alexherbo2 avatar Sep 30 '19 11:09 alexherbo2

I don't mind a hack solution, hence why I don't mind the proposed solution. Besides theoretically speaking, there are workaround to that issue as well. But as you said they'd be ways around to hack into it, instead of proper solutions, (at least the ones I was thinking of).

InvalidWaldo avatar Sep 30 '19 11:09 InvalidWaldo

bspwm uses a binary tree (a container is limited to 2 windows), while i3 uses an n-ary tree (the number of windows in a container is not limited).

I don't really think this is a real problem. As my project shows, you can go from a binary tree to a list of n nodes that are children of a parent. Just traverse the tree in a depth first manner and add the leaves as you find them. Then you could just change the rendering of those nodes if they are in a stack.

I do agree that it doesn't seem to be in the scope of BSPWM itself though, as I don't think it does any rendering outside of windows and their borders. But that to me is a scope issue, not an internal representation issue

TheZoq2 avatar Sep 30 '19 11:09 TheZoq2

Would love to have this feature. Also the only thing which holds me back from bspwm. However I think the name stacked is more appropriate than tabbed. What I basically need is to be able to stack windows on top of each other while having a second window or more beside the stack. Monocle is not sufficient because this would stack all windows on top of each other. I also don't agree that this is not the responsibility of a window manager like suggested by @cadr10 if this is not the responsibility of a wm to manage where windows are placed then who is responsible for that. By this logic monocle should also not exist in bspwm.

Btw I don't mean that I actually need tabs which I visually can see like in i3. I just want the ability to stack windows like in monocle. Its more like the deck-patch in dwm.

astier avatar Dec 09 '19 20:12 astier

Suckless Tabbed might be a solution: https://tools.suckless.org/tabbed/

It works with programs supporting XEmbed. I'm using it with Alacritty.

thugcee avatar Feb 17 '20 18:02 thugcee

Suckless Tabbed might be a solution: https://tools.suckless.org/tabbed/

@thugcee its not because it can only stack windows of the same program. It can not mix different programs. Correct me if I'm wrong.

astier avatar Feb 17 '20 19:02 astier

Suckless Tabbed might be a solution: https://tools.suckless.org/tabbed/

@thugcee its not because it can only stack windows of the same program. It can not mix different programs. Correct me if I'm wrong.

You can mix different programs. Any program implementing XEmbed can be attached.

thugcee avatar Feb 18 '20 09:02 thugcee

Here's a video on bspwm + tabbed: https://youtu.be/tx_dtIijpco

mdutra avatar Feb 20 '20 23:02 mdutra

@thugcee You are right. Last time I used it this somehow didn't work.

astier avatar Feb 26 '20 11:02 astier

Would love to have this feature. Also the only thing which holds me back from bspwm. However I think the name stacked is more appropriate than tabbed. What I basically need is to be able to stack windows on top of each other while having a second window or more beside the stack. Monocle is not sufficient because this would stack all windows on top of each other. I also don't agree that this is not the responsibility of a window manager like suggested by @cadr10 if this is not the responsibility of a wm to manage where windows are placed then who is responsible for that. By this logic monocle should also not exist in bspwm.

Btw I don't mean that I actually need tabs which I visually can see like in i3. I just want the ability to stack windows like in monocle. Its more like the deck-patch in dwm.

I also have the same exact use case in i3, can't live without it. "Stacking" is not possible with tabbed as far as I know (pls correct me if I'm wrong).

shiro avatar Mar 03 '20 23:03 shiro

This is my integration of tabbed with BSPWM: https://gist.github.com/thugcee/87158c313070c666efd43c0a64a2a2e7 It allows seamless joining any neighbouring windows into a tabbed instance (spawned on demand) and separating them back (tabbed closed on last window removed).

thugcee avatar Mar 04 '20 11:03 thugcee

I wish more window managers had this function built in. It would be great if bspwm did.

copper4eva avatar Oct 30 '20 00:10 copper4eva

I suggest to use https://github.com/alnj/polywins

isentropic avatar Feb 04 '21 13:02 isentropic