tags:

views:

166

answers:

1

I always open three windows when writing C code like this:

       |
       |  2 
1      |_____
       |
       |  3
       |

Window 1 is used for code writing, window 2 is used for cscope, and window 3 is used for header file quick reference.

When I press in cscope window to show source, I want Emacs to display .c files always in window 1 while .h files in window 3, is there any possible solution?

Many thanks for your reply.

+3  A: 

Take a look at the answer to a similar question. The key is to use the variable: special-display-regexps. It's nearly a drop-in solution, only you choose the window based on the extension (as opposed to not choosing a window).

Trey Jackson