[Looking for Charlie's main web site?]

Switching among source windows in Eclipse/CFEclipse

Those who know me well know I'm a big fan of keyboard shortcuts. I could give a whole session on them (and perhaps someday will), so I want to share one that I learned and which is useful if using Eclipse, CFEclipse, or FusionDebug. While many know ctrl-tab will swap among windows in many programs, that doesn't work in Eclipse. Try ctrl-F6 instead, which will show a drop down list of open files and let you scroll forward through them. To go backwards in the list, use Shift-ctrl-f6. Cheers.

PS For other keyboard shortcuts I've shared, going beyond things related to CF, check out the category/tag on the topic at my other (older) blog, tipicalcharlie.com: http://www.tipicalcharlie.com/tags/?/keyboard%2Bshortcuts

PPS The entry above on ctrl-f6 is just one more point to be made about looking at Eclipse as a whole when using either CFE or FD. Don't just focus on what those plug-ins add, but rather also on the built-in features of the Eclipse interface which may help you with day-to-day functionality.

Comments
It is also good to note that it is /very/ easy to re-assign the shortcut to a CTRL-TAB if one so desires...
# Posted By Critter | 11/20/06 7:16 PM
Cool to hear, Critz. Please do elaborate for the folks at home. :-)
# Posted By Charlie Arehart | 11/20/06 7:37 PM
Sure mate..


In Eclipse:

Window / Preferences
General / Keys

Scroll all the way down to the bottom. About 12th from the BOTTOM you will see category "Next Editor".
Double Click that line. The modify screen for that action will open up.
Set focus to the Key Sequence section, and hit CTRL-TAB, then click the ADD button. You should now see TWO commands for "Next Editor". You can now select the original one, and click Delete.
Hit Apply... and Bob's yer uncle.. You are sorted
# Posted By Critter | 11/20/06 7:46 PM
I find that CTRL+PageUp/Down works fine, although I do miss CTRL+TAB, so that's a great little tip...
# Posted By David Low | 11/21/06 4:04 AM
Hi charlie,

Instead of CTRL (Or Apple key if you are on a mac) + F6, CTRL + E I find is easier on the fingers and does the same :)
# Posted By Andy Jarrett | 11/21/06 5:50 AM
The [CTLR]+[E] shortcut, in my opinion, functions a little better than the [CTRL]+[F6] functionality. The [CTRL]+[E] shortcut allows you to type in characters to filter you list down and then you use the arrow keys and then the [ENTER] to navigate to the page. There are times when I might have 20+ files open and I find this method more convienent.
# Posted By Dan G. Switzer, II | 11/21/06 9:26 AM
Guys, thanks for all these extra tips. The fact is that we've now identified 3 very different approaches. They're not all the same, though they're indeed all worth knowing about as alternatives.

First, David's Ctrl+pgdn/up does indeed work more like ctrl-tab then either of the others. It just jumps to the next or previous open file. Interestingly, when at the right-most displayed file, it switches to working like the Ctrl-E option Andy mentions.

And that differs from the ctrl-f6 option in the way that Dan mentions: it shows the pop up of files like ctrl-f6, but it adds the ability to type in characters to find matching file names.

All very nice. I didn't know about any of them so I hope that one of them appeals to readers. Cheers.
# Posted By Charlie Arehart | 11/21/06 11:27 AM
Adobe has a keycut for most of their apps, used to switch back and forth between open windows.

It's:
CTRL + TAB to move forward through the list
CTRL + SHIFT + TAB to move backward through the list

That's how I've got my mappings.
# Posted By Andy Matthews | 1/23/07 12:10 PM
Sure, Andy, and Critter had said the same in the first comment above, and offered the steps on how to do it in a subsequent one. BTW, the use of Ctrl-tab is not restricted to Adobe apps. Most do it, from my experience. But yes, it's nice to add that to Eclipse as discussed above.
# Posted By Charlie Arehart | 1/23/07 3:31 PM
I've mapped my next/previous editor keys to CTRL-TAB/CTRL-SHIFT-TAB, but I'm still unhappy with their behaviour, because instead of going to the next active tab in the displayed order, these commands cycle through the recently activated tabs. I know some people prefer it this way, but I'd rather change it and unfortunately I couldn't find any way to do that :(
# Posted By Rau | 2/5/09 4:51 AM
BlogCFC was created by Raymond Camden. This blog is running version 5.005.

Managed Hosting Services provided by
http://www.edgewebhosting.net/
Managed Dedicated Hosting