digiarnie
digiarnie

Reputation: 23345

Eclipse: Files opened by multiple searches using same editor tab

When using the "file search" function in eclipse to find a bit of text in a ".java" file, I may get a list of several search results. Let's say I double click on the file "A.java" which then opens A.java in a new editor tab. If I then use the "file search" function again to find some other bit of text and this time double click on the file "B.java", this file will replace "A.java" in the editor.

I'd like Eclipse to open a new editor for B.java so that both A.java and B.java are available in my editor tabs. Is this possible? I've had a look around in the preferences but I'm not sure what option would give me this bit of functionality.

Upvotes: 138

Views: 27481

Answers (2)

prageeth
prageeth

Reputation: 7395

Above is the best answer. But since I don't always want to open the search result in a new tab I usually use something like this.

right click on the result -> Show In -> Package Explorer ->(file is now automatically selected)->Press 'Enter'

More simply

Select the result -> alt + shift + w -> Package Explorer -> press 'Enter' twice

Upvotes: 12

Chris Lercher
Chris Lercher

Reputation: 37778

Disable the option

Preferences > General > Search > Reuse editors to show matches

Upvotes: 260

Related Questions