[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/bufferlo db02b09c93 141/192: Tab bookmarks now save/res
From: |
ELPA Syncer |
Subject: |
[elpa] externals/bufferlo db02b09c93 141/192: Tab bookmarks now save/restore the tab's explicit-name and group |
Date: |
Sat, 19 Apr 2025 15:58:15 -0400 (EDT) |
branch: externals/bufferlo
commit db02b09c93be913d18ae65bf57bf17bf234be999
Author: shipmints <shipmints@gmail.com>
Commit: shipmints <shipmints@gmail.com>
Tab bookmarks now save/restore the tab's explicit-name and group
For users that override tab-bar behavior with their own tab- or
group-naming functions, this is innocuous.
---
bufferlo.el | 31 +++++++++++++++++++++++--------
1 file changed, 23 insertions(+), 8 deletions(-)
diff --git a/bufferlo.el b/bufferlo.el
index 32f281ecb6..b5aa953ff7 100644
--- a/bufferlo.el
+++ b/bufferlo.el
@@ -2133,13 +2133,20 @@ local buffer list to use. If it is nil, the current
frame is used."
(defun bufferlo--bookmark-tab-make (&optional frame)
"Get the bufferlo tab bookmark for the current tab in FRAME.
FRAME specifies the frame; the default value of nil selects the current frame."
- (let ((filtered-buffers
- (with-selected-frame (or frame (selected-frame))
- (bufferlo--bookmark-filter-buffers frame))))
- `((buffer-bookmarks . ,(bufferlo--bookmark-get-for-buffers-in-tab
filtered-buffers))
- (buffer-list . ,(mapcar #'buffer-name filtered-buffers))
- (window . ,(window-state-get (frame-root-window frame) 'writable))
- (handler . ,#'bufferlo--bookmark-tab-handler))))
+ (setq frame (or frame (selected-frame)))
+ (with-selected-frame frame
+ (let ((filtered-buffers
+ (bufferlo--bookmark-filter-buffers))
+ (current-tab (bufferlo--current-tab)))
+ `((tab-explicit-name . ,(when (alist-get 'explicit-name current-tab)
+ (alist-get 'name current-tab)))
+ (tab-group . ,(alist-get 'group current-tab))
+ (buffer-bookmarks . ,(bufferlo--bookmark-get-for-buffers-in-tab
+ filtered-buffers))
+ (buffer-list . ,(mapcar #'buffer-name
+ filtered-buffers))
+ (window . ,(window-state-get (frame-root-window) 'writable))
+ (handler . ,#'bufferlo--bookmark-tab-handler)))))
(defun bufferlo--ws-replace-buffer-names (ws replace-alist)
"Replace buffer names according to REPLACE-ALIST in the window state WS."
@@ -2306,7 +2313,15 @@ this bookmark is embedded in a frame bookmark."
('new
(unless (consp current-prefix-arg) ; user new tab suppression
(let ((tab-bar-new-tab-choice t))
- (tab-bar-new-tab-to))))))
+ (tab-bar-new-tab-to)
+ (let ((current-tab (cdr (bufferlo--current-tab)))
+ (tab-explicit-name (alist-get 'tab-explicit-name
bookmark))
+ (tab-group (alist-get 'tab-group bookmark)))
+ (when tab-explicit-name
+ (setf (alist-get 'name current-tab) tab-explicit-name)
+ (setf (alist-get 'explicit-name current-tab) t))
+ (when tab-group
+ (tab-bar-change-tab-group tab-group))))))))
;; Handle an independent tab bookmark inside a frame bookmark
(when (and bookmark-name
- [elpa] externals/bufferlo d0c7a52f21 107/192: Add bufferlo-frame-sleep-for to the configuration example, (continued)
- [elpa] externals/bufferlo d0c7a52f21 107/192: Add bufferlo-frame-sleep-for to the configuration example, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo b28c594d3b 110/192: Code cleanup, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 7cbff687d7 112/192: Fix message, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 63dace8685 128/192: Use numeric equality for prefix-numeric-value's, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 27dc075339 133/192: Correct bufferlo--tab-bar-undo-close-tab-advice duplicate check, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo f9113a6e7e 134/192: Add bookmark handler post-load callback functions and docs, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 1b7ed15387 135/192: Ignore tab-bar--tab advice on Emacs 31, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 37192fc6a7 136/192: Wrap 'bufferlo--bookmark-tab-handler' 'tab-bar-new-tab-to', ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 0f08341f43 137/192: Synchronize tab bookmark entries bookmark list and buffer list, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 9e4e1efa73 142/192: Quiet flymake and byte-compiler warnings, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo db02b09c93 141/192: Tab bookmarks now save/restore the tab's explicit-name and group,
ELPA Syncer <=
- [elpa] externals/bufferlo 8e3011e64c 145/192: Change idle timer to regular timer (BREAKING CHANGE), ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 3e8e528abd 146/192: Fix bufferlo--bookmark-completing-read for vanilla Emacs completion, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 76d3dbdf0f 147/192: Add completing-read-multiple and enhance completing-reads, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo c000d9fa13 150/192: Use numeric equality for prefix-numeric-value's, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 1987ce6210 156/192: Add bookmark handler post-load callback functions and docs, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo b431ec33cf 159/192: Synchronize tab bookmark entries bookmark list and buffer list, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 82bb850da9 163/192: Tab bookmarks now save/restore the tab's explicit-name and group, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo febbdfb9ee 161/192: Improve 'bufferlo-mode-line' and mode on/off behavior, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo e7041c36a3 160/192: Silence byte-compiler, ELPA Syncer, 2025/04/19
- [elpa] externals/bufferlo 812892ec92 164/192: Allow both old and new define-ibuffer-op macro references to coexist, ELPA Syncer, 2025/04/19