Question:
It is necessary temporarily, before pressing the "Enter" key, to switch to a special mode when all keyboard commands are redirected and executed in the buffer of the "other" window (other-window).
Why is it needed. While working with Slime, when setting up some function, you have to constantly perform the same sequence of actions:
- Fix function
-
Cc Cc
– compile function -
Cx o
– switch to "other" window buffer (repl is running there) -
Mp
– repeat the last REPL expression, it is possible to change it -
Enter
– execute the last expression in the REPL -
Cx o
– return to the original window
So, I would like to exclude points 3 and 6 so that the sequence of actions becomes this:
- Fix function
-
Cc Cc
– compile function - Enter temporary control of the "other" window (there is still a REPL)
-
Mp
– repeat the last REPL expression, it is possible to change it -
Enter
– execute the last expression in the REPL and return to the original window
A similar problem occurs when calling help for Ch f
. The help text opens in a "different" window and overrides the REPL, while the original window remains active. And it turns out that to close the help you need to do one extra switch to the "other" window, since after closing the help it still returns to the original one.
Answer:
Don't really understand what the problem is? We just hang a function on Cc Cc that will first compile and then switch to another buffer, and on enter a function that will execute the expression and return the buffer.