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

Keybindings to close current tab? #247

Open
lararosekelley opened this issue Nov 18, 2024 · 1 comment
Open

Keybindings to close current tab? #247

lararosekelley opened this issue Nov 18, 2024 · 1 comment

Comments

@lararosekelley
Copy link

I'm hoping to write a function to allow me to redefine evil-quit in Evil mode so that when I type :q it does the following:

  1. Close current window if more than one window
  2. Close current centaur tab if more than one tab in current tab set
  3. Quit emacs if only one window/one tab

To do this, I need some way to call centaur-tabs-buffer-close-tab, but I'm not sure how to get the currently active tab to pass along - I noticed that centaur-tabs-do-close only responds to a mouse event. Is there a way to replicate that behavior programatically without the mouse?

@jcs090218
Copy link
Collaborator

The tab displays depend on the buffer lists. If the buffer is killed, the tab is killed.

This is a bit out of the scope, so I recommend you add those changes to your configuration. You can also consider contributing to https://github.com/emacs-evil/evil-collection.

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

2 participants