When I was on Netbeans I could extremely easily generate template: pressing 'Ob' + TAB I received 'Object', or 'St'+TAB produces 'String'.
In eclipse I created my own template that generates 'Object' by typing 'Ob'.
After I type 'Ob' I need to press CTRL+SPACE to call that template and eclipse instead of generating 'Object'
gives me huge list of all classes that start with 'Ob'. It is not convenient at all.
Does anybody know what to do in eclipse to have code template generation by pressing TAB instead of CTRL+SPACE?
Here is the list of proposal that will show up for CTRL-Space: Windows | Preferences | Java | Editor | Content Assist | Advanced
You could uncheck everything except Template Proposals in the top listing box.
Note also the bottom listing - this is the order in which proposals show up of you hit CTRL-Space repeatedly - by default the Template Proposals show up on top the second time you hit CTRL-Space.
Indeed when I hit ctrl+space twice I see my own template proposals. However I found a way to show up list of template proposals by pressing key binding.
Go to Windows - Preferences - Java - Editor - Content Assist - Advanced. There you will see sentence under first table:
Individual key bindings can be assigned to each proposal kind on the 'Keys' prefernces page
Click Keys word and type 'template proposal' in filter box.
Select Content Assist (Template Proposals) and assign key binding Shift+Tab(but not Tab) by clicking on button with right arrow. Press Apply and then OK button.
Type 'try' and press Shift+Tab. You will see list with single proposal to build try catch block. Hovewer my own code templates are generated automatically by pressing Shift+Tab without any popup lists!