13

Suppose I have a source file open and I launch a shell. I can hit C-x o to switch between the two buffers. But how can I get it so that when I move the mouse the buffer under the mouse gets focus, just like the "focus follows mouse" option common in window managers?

viam0Zah
  • 25,949
  • 8
  • 77
  • 100
numerodix
  • 876
  • 7
  • 20

2 Answers2

19

Set:

(setq mouse-autoselect-window t)
numerodix
  • 876
  • 7
  • 20
3

Answering the shift+arrow comment, do in your .emacs:

(windmove-default-keybindings)