Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse auto suggesting and filling in variable names

Tags:

eclipse

Okay, so my issue is when I am creating a variable, lets say for example "Object o" while I am typing "o" it'll suggest something like "object". Which is okay but when I press space it auto fills in the new name. Basically I don't want to turn off auto completion I just want to disable space auto filling the suggestion in. Even to disable variable naming suggestions would work.

I'm using Eclipse Juno Service Release 1.

like image 225
Fiachra Avatar asked Feb 14 '13 13:02

Fiachra


People also ask

How do I autocomplete variables in Eclipse?

Code Assist is triggered automatically in a number of situations (for example, typing the "." after a variable name or class name). However, it can also be forced at any time using Ctrl-Space (remember Mac users, this shortcut doesn't change on a Mac).

How do I turn off auto suggestion in eclipse?

Open menu Window, then Preferences. Follow path Java -> Editor -> Content assist. Now mess around with the settings to find your ideal setup. I believe what you'll want is to deactivate Insert single proposals automatically.


3 Answers

I know it's an old question but since non of the answers here worked for me, and this problem was really annoying me too, I am adding solution that helped me.

In your Eclipse go to: Window/Preferences/Java/Editor/Content Assist

and enable:

Disable insertion triggers except 'Enter'

screen/shotted

Hopefully that will work for everyone!)

like image 119
Alien Avatar answered Nov 10 '22 21:11

Alien


Go to Window/Preferences/Java/Editor/Content Assist and choose settings that works for you.

like image 39
rebeliagamer Avatar answered Nov 10 '22 19:11

rebeliagamer


As there isn't any definitive solution for this yet, what I find works best is to disable the alphabetic characters from triggers:

Windows > Prefereces > Java > Editor > Content Assist > Auto activation triggers for Java

This will mean no class name / type completion, but method name completion will still be suggested when you pressed dot, however at least Eclipse stop messing with my variable name

like image 3
gerrytan Avatar answered Nov 10 '22 19:11

gerrytan