0

Could someone please explain how to use default-frame-alist to make list-buffers switch to the resulting results buffer? list-buffers uses display-buffer so I am thinking that display-buffer-alist is the object I should be tweaking to ensure that the buffer "*Buffer List*" gets focus via switch-to-buffer.

0

In the end the answer was straightforward enough: create my own function to do just that with the correct calling interface:

(defun my-switch-to-buffer-list (buffer alist) 
  (select-window  (display-buffer-use-some-window buffer alist)))

The custom addition for display-frame-alist:

'(display-buffer-alist '(("\\*Buffer List\\*" (my-switch-to-buffer-list))))

I don't think there is a way to attach a lambda in the custom interface so this seems a reasonable solution. Something like help-window-select would seem helpful.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.