GOSH! I just wasted a solid hour trying to remember what Eclipse called their “vi style search/find” find feature. I remembered learning about the “vi” style find a few weeks ago (it was on EclipseZone), but could not remember how to get into the find mode. FYI. If you are looking for it, Eclipse calls it Incremental Find.
Anyhow, the two ways to activate Incremental Find in Eclipse are: -via the menu system with Edit -> Incremental Find Next or Incremental Find Previous. -via keyboard shortcut Ctrl-J for forward find and Ctrl-Shift-J for reverse find.
A couple notes on incremental find “odd” behaviors. The first is that when you are searching forward the text you are searching for is highlighted and your cursor is at the end of the string you are searching for. The odd part of this is that if I want to search in an opposite direction, from forward to reverse, the first time I switch the direction my search doesn’t move from one instance of the search term to the next. My cursor just stays on the same search term but moves from the beginning of the term to the end. Yes, I’m being anal here, but it seems like an inefficient movement, just moving the cursor, not moving to the next search term.
Along the lines of the first “odd” behavior. When using incremental find to search for something, and you hit the end of the file, the find doesn’t wrap. The find just lets you know that you hit the end. Then with a second keystroke it wraps to the next search term. I call this “blocking my shot”.
It would be nice if Incremental Find in Eclipse worked a bit more like vi but it’s still a great feature and one that I will be using going forward. And, the main point of this post was to document how to use incremental find, and what it’s actually called (not “the vi kind of find”) so I can talk about it with people.