netbeans icon indicating copy to clipboard operation
netbeans copied to clipboard

autocompletion for assigning variable [ALT + ENTER] does not work any more

Open helper14 opened this issue 1 month ago • 3 comments

Apache NetBeans version

Apache NetBeans 28

What happened

Autocompletion for assigning a variable to a given method automatically does not work anymore. e.g. given the line: getGreeting(); pressing [ALT + ENTER] when positioning the cursor in getGreeting used to complete the code to: String getgreeting= getGreeting();

Now nothing happens. I can't find another (new) way to complete the code.

Language / Project Type / NetBeans Component

code completion

How to reproduce

Type in a line with a method which is returning a value without assigning a variable to the return value. position the cursor on the method, press [ALT + ENTER] ...

Did this work correctly in an earlier version?

Apache NetBeans 25

Operating System

Win11

JDK

JDK 21

Apache NetBeans packaging

Apache NetBeans binary zip

Anything else

No response

Are you willing to submit a pull request?

No

helper14 avatar Nov 25 '25 09:11 helper14

Image

can't reproduce

mbien avatar Nov 26 '25 09:11 mbien

Thank you for the quick response! I have been looking for the crucial difference in my configuration and found the following: When I start with a fresh installation the corresponding code completion works. After importing the "All Other Unspecified" settings from my old configuration it stops working. The import of all other settings does not spoil proper working. Does that help in any way? So the problem has been resolved (at least) for me in this way - should I close the issue?

Image

helper14 avatar Nov 27 '25 16:11 helper14

Does that help in any way?

Yes! Thanks for investigating and posting your results. Interesting that the "unspecified" category of the manual config import is causing this. I might take a look at this for the next release if I can reproduce it myself.

should I close the issue?

lets keep it open for now. We can still close or rename/update it later.

mbien avatar Nov 28 '25 05:11 mbien