Follow

tabs questions:

1) How many tabs (not buffers) do you usually have open?
2) Are there a certain amount that you name for buffers you refer to several times a day?
3) What keybinds (if any) did you set to flip through them quickly?
4) Which tab system/package do you use?
5) If you use Mastodon.el, do you have a dedicated tab? More than one?

@dekkzz76

1) Cool
2) Like permanent ones you keep just one buffer open in, for example your daily todo.org, your daily notes, etc....
3) Your poor fingers. 🤣
4) Ok.

@natharari

tabs i use: dashboard, either guile, tcl, prolog or raku programming window setup, scratchpad.org, notmuch mail, elfeed, weechat in vterm

FWIW i use (tab-bar-mode 1) in my init.el

with only 4 to 6 tabs i don't feel the need for extra keybindings, if i had a lot more open & i think many ppl do then i probably would have them, i use the trackpoint on my thinkpad for the tabs so my hands never leave the kb

@dekkzz76 That makes sense. Thanks.

I use the same tab-bar-mode myself, but I was looking into Centaur. Just curious about it. But I like the minimalism of the default tab bar. It's very thin and takes up barely any room.

@natharari

i customised the active bar to be in bold font - might play with the colours yet

if you have a lot of tabs the famous Prot does a package to organise/group tabs by function or frame on his site.

@dekkzz76 Yeah I was looking into that as well, but I tend to limit my tabs to a maximum of about 8-12 maybe.

@natharari
I don't use tabs, I re-bind "C-x b" to the Vertico+Consult switch buffer function which lets me switch to any buffer by name very quickly. Also, the project.el functions are good enough to switch between files and buffers realted to a parcitular a project, especially when used with Vertico.

If I really need to separate groups of windows, I open a new frame and use my window manager to switch between frames. I do this sometimes when following multiple channels on IRC.

@ramin_hal9001 I use the same C-x b as well. 👍

I just like static access points for some files (such as todo.org, repeat.org, chatgpt, dashboard, etc...) things I refer to many times a day. I set it so that I can flip through the tabs very quickly back and forth so it's generally faster than C-x b and typing a few letters to bring up the relevant buffer. Also, flipping through them, I realise I lose track of things sometimes in my head and a visual reminder when I'm flipping through allows me to remember to do something on that buffer.

@natharari I launch with 2 tabs (Mail and Org, named thus) in tab-bar-mode.

I open a 3rd tab for everything else. Sometimes more to get contexts quickly. Usually, I have some Magit buffer open at all times in the 3rd during work.

⌘1--⌘9 for quick tab switching (default Mac shortcuts)

Also bound my leader key + `t` to use the tab key map.

@natharari See here for the config:

gist.github.com/DivineDominion

Also search for `display-buffer-alist' for my overrides to dedicate stuff to tabs

@natharari oh, and picture (added the (1)--(9) to the tab format characters to make jumping between them based on numbers easier)

@natharari "1 tab" as I've never had the urge to start with tabs after setting up my concept using #eyebrowse and their named "tabs" (AFAIR they use "sessions") of buffers if you wish.

I'm not using Mastodon.el but I'd ask tons of questions to people who do.

@publicvoit Oh it was just general curiosity. It's always interesting to see how people use Emacs because of the infinite ways in which you can configure and use it. Sometimes I get ideas for my own use by seeing how other people use it and then add some things to my own config of course.

Also, I used to use eyebrowse but I never really stuck with it. I did like it for a while though.

@natharari #emacs
1) 2-3, depending on the use
2) Not really
3) C-x t 2 for opening, 0 for closing
4) tab-bar
5) Not using mastodon.el (not yet, at least).

@jcastp

1) Cool.
2) OK
3) I guess you don't switch tabs often?
4) Cool
5) I am chagrined and saddened! 😲

@natharari
To switch tabs, I use C-Tab or C-Switch-Tab, same key shortcuts as in Firefox.

Point 5 is in my TODO list 😜

@natharari
1) 5-7 tabs open in my note-taking frame, similar in code frames
2) No
3) C-comma and C-period for previous/next-buffer
4) tab-line
5) Don't use mastodon.el

@wirthy

1) Cool
2) OK
3) I really like that.
4) Interesting
5) Shocking! 😃

@natharari 1. Usually one "tab" (perspective) for a project or Emacs app.

2. I have dedicated perspectives for apps like EMMS, notmuch, telega.el, etc. Which I usually create at the start of the day and then refer to them during the session.

3. s-0..9 to switch EXWM workspaces, s-<, s-> to switch perspectives in a workspace.

4. perspective.el, EXWM, and a bunch of stuff on the top. For instance, I have a set of rules that auto-assign buffers to perspective / workspace depending on their mode.

I also wrote a package that allows for copying / moving perspectives between workspaces.

5. Yeah, one dedicated perspective for mastodon.el on workspace 0.

@sqrtminusone

1) So, basically, just one single buffer with no tabs, right?
2) So perspectives replaces tabs for you. I used to do that too. It's a cool system. 👍
3) Nice.
4) I like that idea.
5) Yeah. I have one dedicated tab for it. It's useful that way.

I like your system a lot. It seems to reflect mine but with perspectives instead of tabs. Are there certain advantages for you in using perspectives instead of tabs? I'm curious.

@natharari I mean, if I'm working on a client-server project, I have a perspective called "term" for Alacritty (which goes there automatically), and either one perspective for the entire project or one for the backend and one for the frontend.

Essentially, the key difference is that a perspective is a group of buffers, while a tab is a view for the same global set of buffers. Since I wanted the former, I went with perspective.el.

...or at least this was the case when I made that choice, because tab-bar.el seems to have been inspired by Vim tabs. Since then, some 3rd party packages appeared that essentially replicate the behavior of perspective.el with tab-bar.

But perspective.el does all of that out-of-the-box, I have grown quite familiar with the inner workings of the package, and it got into a lot of things in my setup (such as this auto-assignment logic), so I'm not particularly eager to switch.

Another important thing to me was the integration between Treemacs and perspective, which allows to have one perspective = one instance of Treemacs = one or multiple git projects. However, I no longer use Treemacs.

@sqrtminusone I see. It makes sense. It's like tab grouping in Safari it seems.

I also didn't know that you can run Alacritty in Emacs?

@sqrtminusone Ah yes. Good point. I'm on a Mac and I use Warp terminal with AI built in so, I'll have to pass. 😀

@natharari I use project-tab-groups mode. So I have:
1) a tab per git project open + 1 garbage tab for scratches and other stuff.
2) tabs get named based on project dir
3) M-page up and M-page down
4) already answered

@natharari

1) 6 2) no 3) M-[2-9] 4) tab-line + config 5) not yet

I have things set up so the most recent buffer is always the left-most tab, and the tabs are sorted by most recent usage, up to 6 shown. Makes it quick to switch among several recent buffers. I usually track this in my head for 2-4 buffers, the tabs are a crutch for more than this or when I am not sure.

Sign in to participate in the conversation
Qoto Mastodon

QOTO: Question Others to Teach Ourselves
An inclusive, Academic Freedom, instance
All cultures welcome.
Hate speech and harassment strictly forbidden.