0

This may be a silly question, but how can I make a buffer unreachable? I have enabled live-py-mode. Every time I try to edit my python file it evaluates the code, which is a well and good but it's a little annoying how it switches focus from the source file to the eval result. Is there a way I can prevent changing focus from source to result?

1
  • 1
    Maybe this description is clear to a Python user of Emacs; I can't say. To me (not such a user) it's not clear. If you think it might be unclear to others, consider providing a step-by-step recipe to demonstrate the problem, starting with emacs -Q (no init file). Commented Mar 28, 2020 at 5:20

1 Answer 1

1

Edit: In hindsight, I think I've answered a somewhat different question, and that your actual question probably requires direct knowledge of live-py-mode (which I don't have). I would suspect that if the window in question is being selected and that doing so makes no sense, then this is probably a live-py-mode bug to be raised with its author?

The following answer was aimed at preventing a particular window from being displayed at all...


You can use the display-buffer-no-window action with display-buffer-alist, but you need to know how to identify the buffer.

Here I have assumed the buffer is always named *py-live-eval*, and have specified a regexp matching that.

(add-to-list 'display-buffer-alist
             (cons "^\\*py-live-eval\\*$"
                   (cons 'display-buffer-no-window
                         '((allow-no-window . t)))))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.