diff options
| author | Constantine Vetoshev <gepardcv@gmail.com> | 2021-03-09 16:25:10 -0800 |
|---|---|---|
| committer | Constantine Vetoshev <gepardcv@gmail.com> | 2021-03-09 16:25:10 -0800 |
| commit | 1070f406209e6251657788115b7f05a5b5cdeaf9 (patch) | |
| tree | a0c3fb14c69fe68c3d7a201811322a1a3ca21f00 | |
| parent | 9605e533b6e15ded612430f67468b08e2e8209ea (diff) | |
| parent | 1619fb8ae9cf579a8e344eaa60f2f33032d1a3cb (diff) | |
Merge branch 'titibandit-master'
| -rw-r--r-- | README.md | 5 | ||||
| -rw-r--r-- | perspective.el | 10 |
2 files changed, 15 insertions, 0 deletions
@@ -166,6 +166,11 @@ to use a Perspective-aware buffer switcher. in particular its `ido-switch-buffer` command, is automatically Perspective-aware when `persp-mode` is enabled. +**buffer-menu**: Perspective provides a wrapper for +[`buffer-menu`](https://www.gnu.org/software/emacs/manual/html_node/emacs/List-Buffers.html): +`persp-buffer-menu`. When this function is called normally, it shows the buffer menu filtered by the current perspective. With a prefix argument, it shows the +buffer menu of all the buffers in all perspectives. + **`bs.el`**: Perspective provides a wrapper for [`bs-show`](https://www.gnu.org/software/emacs/manual/html_node/emacs/Buffer-Menus.html): `persp-bs-show`. When this function is called normally, it shows a list of diff --git a/perspective.el b/perspective.el index 177f1e2..e1100ce 100644 --- a/perspective.el +++ b/perspective.el @@ -1261,6 +1261,16 @@ PERSP-SET-IDO-BUFFERS)." (buffer-name (current-buffer)))))) (kill-buffer buffer-or-name)) +;; Buffer switching integration: buffer-menu +;;;###autoload +(defun persp-buffer-menu (arg) + "Like the default C-x C-b, but filters for the current perspective's buffers." + (interactive "P") + (if (and persp-mode (null arg)) + (switch-to-buffer + (list-buffers-noselect nil (seq-filter 'buffer-live-p (persp-current-buffers)))) + (display-buffer (list-buffers-noselect)))) + ;; Buffer switching integration: bs.el. ;;;###autoload (defun persp-bs-show (arg) |
