Eclipse doesn't highlight references anymore

I have an odd problem. In Eclipse Ganymede, I used to be able to highlight a variable, and it would highlight the use of that variables in that method. However through some action I have now disabled it. Is there a way I can enable it?

I tried searching Google, but since I don't know what the feature is called, its kinda tough.

Its a really useful feature, and its annoying that its not working.


There's a little "highlighter" icon on the toolbar - it toggles "Mark Occurrences".

From the preferences window, the feature you mean is configured by navigating to:

Window -> Preferences -> Java -> Editor -> Mark Occurrences

屏幕截图


There's a little "highlighter" icon on the toolbar - it toggles "Mark Occurrences".

You probably accidentally pressed it when trying to select a menu item at some point. I had a friend who did that with the "show selected element only" toolbar button...

You can either press it again or configure as Rytmis says.


Press alt-shift-O.

It toggles the "Mark Occurrences" feature of Eclipse; which provides the highlighting functionality you're missing.

链接地址: http://www.djcxy.com/p/37564.html

上一篇: Eclipse热键:如何切换标签?

下一篇: Eclipse不再强调引用