Eclipse only with keyboard - eclipse

I'm trying to be more productive with eclipse in Linux by using just the keyboard. I find relatively easy to use the shortcuts, but I struggle with popup windows. For example, when creating getters and setters, I have to press Shift + Alt + S, R, and then I have a lot of keys to access each option. Nonetheless, when I want to close the window (Accept) it seems I have to traverse all controls using Tab. Is it the case? Is there a easier way?
Thank you all

If the focus is not on a button you can use Ctrl+Enter to apply and close the dialog.
For canceling the operation hit Esc, which also closes the dialog.

Related

Is there a shortcut for switching between panels in eclipse?

Eclipse has an MDI structure (Multi Document Interface), so the search panel, the package explorer and the code editor can all be open in one window, but I haven't found a keyboard shortcut for switching between these panels. For example, after I search the code-base, I would love to have a quick shortcut for going back to the code editor.
If I understand your question correct, you are probably looking for Ctrl + F7 and Ctrl + Shift + F7. Other navigational shortcuts can be found in the menu: Window > Navigation.
Not an universal shortcut for going to any panel, but:
Ctrl+Shift+E
allows you to go back to any Editor (although it's still a little heavyweight for quick editor navigation).
And if you want to switch between perspectives its: Crtl + F8 and Ctrl + Shift + F8. You can go to Help > Key Assist... for a full list of shortcuts (this list will change depending on the active editor etc.).
There are two ways to do it.
One is how #VonC did it, in an earlier reply; using CTRL+SHIFT+E which opens a box containing all the panes with their paths.
The other one is to simply use CTRL+E, which will open a pop-up just over your cursor containing the list of panes open. Parse using arrows and ENTER

How do i use eclipse efficiently by making maximum use of keyboard

I mean to say which and all shortcuts from key board is available while working on eclipse?
like how Ctrl+F11 is for run project like that.
Effective Eclipse: Shortcut keys
Useful Eclipse Shortcut Keys
10 Eclipse Navigation Shortcuts Every Java Programmer Should Know
You can define your own:
FAQ How do I provide a keyboard shortcut for my action?
Provider by MatrixFrog in comments below:
Hidden features of Eclipse
Press ctrl + shift + l it will open shortcut key menu.
Note:-
Beside this also some other short cut will available. If you tell us functionality you wanna access we can tell you the short cut for it.

How to navigate up/down using keyboard home keys in Eclipse's suggestions pop up window?

When Eclipse shows a popup for code completion, how do you change the highlighted option using the keyboard home keys? Currently, if the thing I want is third or fourth on the list of suggestions, I have to use the mouse to select it, or use the arrow keys. Is there a way to use the keyboard home keys/ shortcuts with ctrl/alt to do this?
Arrow keys always work for me. Can you be little more specific as to what perspective, editor, etc?
I get a code completion popup when I press Ctrl + 1 in the Java editor. From then on, I can use the arrow keys to navigate.
I'm assuming you want to select from the code completion menu by X for up and Y for down. Go to Preferences > Keys and bind the commands Line Up and Line Down to X and Y, respectively. Make sure that in the When drop-down you select In Windows.
Note that after the settings are applied, X (Y) also makes the cursor go one line up (down) in the source editor. Personally, I use X = Ctrl+P and Y = Ctrl+N which means I can navigate lines and select entries from the code completion menu without lifting my hands off the keyboard.
Unfortunately, these bindings don't work with other pop-up lists in Eclipse, e.g. quick outline (Ctrl+O) or quick access (Ctrl+3). I'd love to find out how to bind these too.

Is it possible to dock the "Find/Replace" window in Eclipse?

I could have sworn I saw it once before in a screencast where someone had the find/replace window docked in their Eclipse environment.
However looking through the list of options in "Window > Show" the closest thing I can find is the Search window.
I find that I use it quite a bit and with larger monitors these days I figure I could afford to have it open in my perspective all the time.
Is this possible?
Thanks.
One poor-man's workaround is to dock a view that you don't need in a part of Eclipse where you want the find/replace view and then place the find/replace dialog on top of that like this:
Clearly this is a huge kludge but it does work.
I am not sure about that, since Fast views are:
icons allowing users to quickly display different views that have been created as fast views
And the search/replace is a Dialog, not a View..
(source: bpsite.net)
(That Dialog box is not like Views, which support editors, also have their own menus. Some views also have their own toolbars.)
The help page mentions:
Fast views are hidden views that can be quickly opened and closed. They work like other views except they do not take up space in your Workbench window.
This might not be an exact answer for the question. But this works like a charm.
Press ctrl + j and keep typing...
Use ctrl + k to go on
Use shift key wherever required.
Use Edit > Incremental Find Next (Ctrl+J) or Edit > Incremental Find Previous (Ctrl+Shift+J) to enter the incremental find mode, and start typing the string to match. Matches are found incrementally as you type. The search string is shown in the status line. Press Ctrl+J or Ctrl+Shift+J to go to the next or previous match. Press Enter or Esc to exit incremental find mode.

Faster way (keyboard shortcuts?) to use quick fixes in Eclipse?

I often use the Eclipse feature (Galileo) of suggested error corrections to automatically create code stubs or to refactor things. For example, I would write a method that calls other methods which don't exist yet, then move the mouse over the error message and click on "create method". Or, change this to the class name and choose "add static modifier" from the quick fixes.
I think this is very convenient because it lets me stay in one place in my code and sort of "remotely" wire up what's not currently visible on my screen. What I think is annoying though, is that I have to leave the keyboard, hover my mouse over the error symbol, wait for the tooltip to pop up, and click on the option (doing that, I sometimes move the mouse a little over the edge and the tooltip goes away again - very annoying).
Am I missing a faster method here? I can't seem to find a keyboard shortcut, but then I have overlooked stuff from the huge preference dialog before.
Ctrl+1 : Quick Fix.
(Cmd+1 on Mac)
Just put your cursor on the part you suspect you can perform an action (correction, refactoring, ...) and hit the Quick Fix shortcut. The same popup will be displayed, and you can select the right option with the up and down keys.
That, combined with Ctrl+3 (Quick Access) gives you most of eclipse features at your fingertips ;)
See also:
Eclipse Tip: Shortcut to Quick Fix
My Favorite Eclipse Shortcut: Quick Fix
Eclipse hotkeys: eclipse shortcuts gold mine.
As an additional tip, a specific type of quick fix I use all the time has a dedicated shortcut:
Alt+Shift+J: Add Javadoc comment stub for current method.
After using ctrl+1 like mentioned in the top answer, press ctrl + enter to apply the selected fix all to problems of the same category.
In general, keyboard shortcuts in IDEs (and code tools in general) are coming from a user principle that holds that the more your hands/fingers can remain poised over the keyboard (as in the f-j centered "touch typist" position), the more productive you can become. This is probably why the use of the number keypad is not encouraged, or other keys, less common to the most basic layout keyboard, are not used. Many hold that useful keyboard shortcuts should be easily reachable from this position.
One thing I will say about eclipse keyboard shortcuts is that if you use a popular Windows presentation utility called Zoom-it, you need to turn that off when using eclipse. There are several show-stopper conflicts between the two, such as Ctrl-1 and Ctrl-3.