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

Better buffer navigation. #8519

Closed
AnthonyJacob opened this issue Mar 14, 2017 · 13 comments
Closed

Better buffer navigation. #8519

AnthonyJacob opened this issue Mar 14, 2017 · 13 comments
Assignees
Labels
- Mailling list - Buffers stale marked as a stale issue/pr (usually by a bot)

Comments

@AnthonyJacob
Copy link

AnthonyJacob commented Mar 14, 2017

Spacemacs buffer have the following problem:

1) It is very hard to remember where will next/previous-buffer command bring you.
2) It is also on very inconvenient shortcut SPC-b-n which is exactly three keystrokes for one buffer. But I typically want to move to the third or fourth buffer.

Therefore I almost never use anything but SPC-TAB and I kill buffers frequently to not go nuts.

So I am wondering whether there could be better system than the current one.

  1. There could be a bar with buffer names at the top (similar to any web browser or IDE) that would be shared across all windows (similar to spaceline and powerline).
  2. Alt+[0-9] could be used to move between buffers similar to SPC-[0-9] moves between windows or the other way around.
@NJBS
Copy link
Contributor

NJBS commented Mar 14, 2017

What you describe is similar to tabbar-mode, there isn't an official layer for this yet but googling "spacemacs tabbar" will give you some unofficial layers and configurations you can test out.

Also, try looking at the ibuffer layer and see if that helps with your organization woes.

@fiveNinePlusR
Copy link
Contributor

one thing that I like to use but it's not perfect is binding ctrl-shift-left and right arrow to buffer next and buffer previous. makes it much quicker to navigate nearby buffers. if you have an org file open you will have to revert to spc b n and spc b p though or override it in org mode too.

  ;; faster buffer switching
  (global-set-key (kbd "<C-S-right>") 'next-buffer)
  (global-set-key (kbd "<C-S-left>") 'previous-buffer)

I would love for there to be a well executed tabbar mode but the ones that I have found are really bad comparatively.

@yqrashawn
Copy link

yqrashawn commented Mar 22, 2017

I was using tabbar-mode for three months. I disabled it. It kept me from remembering buffer names. I can only remember function names or what does the file do. There's a package called buffer-flip you may have a look at that. It's depend on key chord. And imenu-anywhere is another choice in some cases. And if you decide using tabbar. I modified buffer-flip a little into tabbar-flip.

@ghost
Copy link

ghost commented Apr 23, 2017

I think a saner alternative to tabs would be a plugin that hooks into like neotree to make a tree of buffers in a firefox tree-style-tabs fashion

At the very least it should not be another layer of semantics and just hook into projectile/perspectives

@dijonkitchen
Copy link
Contributor

From my vim days, this was a good implementation of the buffer list in the tabline: https://github.com/vim-airline/vim-airline#smarter-tab-line

@Miciah
Copy link
Contributor

Miciah commented Dec 1, 2018

If you haven't already tried it, check out the buffer transient state. Enter it by pressing SPC b ., and then press n and N (or p) to move forward and backward through buffers.

@kazimuth
Copy link

The treemacs extensions tutorial has an example of something like this, and there's work on a more robust version to be added to master.

@sdwolfz
Copy link
Contributor

sdwolfz commented Sep 20, 2019

I've been thinking about this as it sometimes anoys me as well. Maybe integrating something like https://github.com/manateelazycat/awesome-tab and then having a transient state pop up when SPC b n would be a better UX?

@sdwolfz sdwolfz self-assigned this Sep 20, 2019
@duianto
Copy link
Contributor

duianto commented Sep 25, 2019

Another tabs package is: https://github.com/ema2159/centaur-tabs

@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!

@github-actions github-actions bot added the stale marked as a stale issue/pr (usually by a bot) label Sep 24, 2020
@duianto
Copy link
Contributor

duianto commented Sep 25, 2020

The following PRs changes have been applied to the develop branch:
[layers/+emacs/tabs] introduces tabs layer with Centaur backend #13907

@sdwolfz sdwolfz removed the stale marked as a stale issue/pr (usually by a bot) label Sep 25, 2020
@sdwolfz
Copy link
Contributor

sdwolfz commented Sep 25, 2020

Awesome, I'll work with @WarFox in the following days to improve the key bindings.

@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!

@github-actions github-actions bot added the stale marked as a stale issue/pr (usually by a bot) label Oct 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
- Mailling list - Buffers stale marked as a stale issue/pr (usually by a bot)
Projects
None yet
Development

No branches or pull requests

10 participants