1. 程式人生 > >Eclipse 中雙擊變數不高亮 切換變數不高亮 解決

Eclipse 中雙擊變數不高亮 切換變數不高亮 解決

在eclipse/myeclipse中如果不小心把變數的高亮顯示弄丟了。可真是件愁人的事,不過看到這你就不用愁了

windows->   preferences-> java-> Editor-> Mark   Occurences 

最上邊的大標題的複選框勾上,下面的就都可以高亮顯示了,Local   variables是變數的高亮顯示

還有其他的一些高亮的

alt+shift+o 也可以開啟關閉這個

======================== 以上是設定

 下面的是切換變數的時候不高亮 ---測試可以

http://blog.csdn.net/ritterliu/article/details/19087431

Two "solutions" that at least get the highlight stuck on a new item (!!):

  1. As @Subas Raj mentioned, defocus and refocus the window - when you come back, your current position is occurrence-highlighted. Either hit AltTab twice, or use your mouse to click/focus some other window, then back.
  2. As @Leo and @Gorky mentions, hit Alt
    ShiftO twice. This is the shortcut for toggling highlight occurrences, and when you turn it back on, your current position is occurrence-highlighted.

親測可行, 就是反應略卡。