Emacs RTags: rtags-find-references-at-point

143 Views Asked by At

I just installed RTags with Emacs but I am a bit frustrated because while using "rtags-find-references-at-point", Emacs open another window with the different references but do not focus on it. Meaning, each time I am using this functionality, I have to manually switch to that window. It is a normal behavior ? Or is there a way to overcome this "issue" ? Thank you.

2

There are 2 best solutions below

0
manzerbredes On BEST ANSWER

I finally decided to use the following function:

(defun rtags-find-references-at-point-focus ()
  (when (rtags-find-references-at-point)
  (select-window (first (get-buffer-window-list "*RTags*")))))
0
tereshkd On

I found it quite easy to use next-error and previous-error functions: global bindings M-g n and M-g p by default.

This will jump between different matches while keeping the focus in the current window.

The problem I'm trying to solve now is a pretty random window split every time.