File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes IDEs, Version Control and other tools and the fly likes Eclipse Ganymede - keeps autoselecting function name as I type! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "Eclipse Ganymede - keeps autoselecting function name as I type!" Watch "Eclipse Ganymede - keeps autoselecting function name as I type!" New topic
Author

Eclipse Ganymede - keeps autoselecting function name as I type!

Eli Wood
Ranch Hand

Joined: Sep 04, 2008
Posts: 37

This is really annoying. Tried google but didn't know the correct search terms.

Basically as I type out a function, for example:

public String test(){return "";}

Eclipse keeps trying to highlight/auto-select function name (in this case the word "test"). So if I'm being thoughtful or considering a problem and not typing very fast, I end up having to wait, then use the arrow keys to change the focus back where I want it so I don't type over my function name repeatedly.

Anybody know how to fix this?

Thanks for your help and consideration.
Ilja Preuss
author
Sheriff

Joined: Jul 11, 2001
Posts: 14112
I have never seen this happening. Sounds mysterious to me...


The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38353
    
  23
You must have the autocomplete on. It usually works after a . ; that produces a drop-down list of possible choices. I usually find that continuing to type will narrow the choices. There is bound to be a way of turning it off, but since that is a common IDE feature, I usually leave it on, so I don't know how to disable it.

Sorry.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

No, originally I thought that Eli was describing autocomplete, but that isn't it. Autocomplete in Ganymede annoys me sometimes, especially when my machine is overloaded, but I find that deliberately misspelling a method name and then backspacing to correct it will make the autocompletion function go away.
Eli Wood
Ranch Hand

Joined: Sep 04, 2008
Posts: 37

Yeah, this is different than autocomplete. I've tried turning off some of the Automatically close options under java->typing and auto-activation under java->content assist and neither really helped.

Good to know (well, not that good to know) I'm not the only one baffled by this. It seems to go away (sometimes) after restarting Eclipse. But then it comes back later.

I think it has something to do with the validation/syntax checking, only instead of just highlighting the error (the error would be that my function declaration isn't complete, as I haven't fully typed it, or doesn't return the correct type) it's actually going ahead and selecting it.

I get the feeling this will end with me going with the path of least resistance typing out my functions in a convoluted mostly-backward way as soon as I can find a pattern that fully avoids this issue.
Roger Henderson
Greenhorn

Joined: Oct 30, 2008
Posts: 1
I have the same problem - eclipse wanting to select the method name when I make a change anything in the method 'signature'.

I've also had this sometimes happen when typing within the method body. Damn annoying!!

I'm using Rational Application Developer which is based on eclipse 3.2

If anyone can point us at a setting somewhere that would be great!

Roger
Marcel Dullaart
Ranch Hand

Joined: Nov 07, 2007
Posts: 55
Hi
I have seen this quite annoying issue as well on Ganymede!
It just seems to pop-up every now and then. And it goes away, but I cannot pin point (yet) what causes this.


"It would be faithless now to say farewell." (FotR, p. 419)
http://marcels-javanotes.blogspot.com/
Craig Harrison
Greenhorn

Joined: Nov 04, 2008
Posts: 1
I too have been frustrated for days with this but think I may have a solution.

In the Project Explorer/Navigator there is an icon with two horizontal arrows pointing in opposite directions - "Link open editors with content..." - that if enabled navigates to the current file on the Project Explorer window. De-selected that option and the auto-selecting annoyance goes away.

The obvious down side is that the linking feature is then disabled...
Carl Pritchett
Greenhorn

Joined: Mar 03, 2009
Posts: 2
I had this happen on Eclipse 3.3 - method names were selected (and highlighted in grey) after a shory delay in typing, then the next key press would overwrite the method name.

I tried many pref changes to no avail. Also turning off "Link open editors with content..." did not fix the issue.

I closed all files and restarted Eclipse and the issue went away. So it seems to be a sporadic bug.

Regards,
Carl.
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14107
    
  16

Are you talking about the feature "Mark Occurrences"? There's a button on the toolbar to toggle this, or you can use the key combination Alt+Shift+O.



[Thumbnail for eclipse-mark-occurences.png]


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Carl Pritchett
Greenhorn

Joined: Mar 03, 2009
Posts: 2
Are you talking about the feature "Mark Occurrences"?


It's definately not mark occurrences - it does more than just highlight the method / member name - it also "selects" it - causing a pause in typing to overwrite what you just typed.

I turned of mark occurrences and it still happens. It's happened twice for me in one day.

The only new things I've done is started a new Dynamic Web Project and installed Cypal Studio for GWT development. Any one else added this facet?

Carl.
Vladimer Shioshvili
Greenhorn

Joined: Mar 06, 2009
Posts: 1
Don't know about others but Craig Harrison's suggestion worked for me (I'm using Eclipse 3.4.1) - as a result i will be cursing less while typing these days. Thanks!
Scott Reed
Greenhorn

Joined: Mar 15, 2009
Posts: 1
This appears to be fixed in 3.4.2 so you can go back to having the content linked with the navigator and not have the editor selecting it's own text while you are typing. Enjoy!
Ricky Long
Greenhorn

Joined: May 06, 2009
Posts: 1
On Project Explorer, if you minimize the class to hide the methods, then the problem goes away. You still can have both "Toggle Mark Occurrence" and "Link editor with Explorer" selected. Not a solution, but at least a way to avoid getting annoyed.
Anupam Jain
Ranch Hand

Joined: Mar 16, 2010
Posts: 61

Ricky Long wrote:On Project Explorer, if you minimize the class to hide the methods, then the problem goes away. You still can have both "Toggle Mark Occurrence" and "Link editor with Explorer" selected. Not a solution, but at least a way to avoid getting annoyed.

Yup.. Ricky's solution worked for me... and no need to disable the linking arrows (Really useful for me)



SCJP-6.0 OCPJWCD-5.0
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Eclipse Ganymede - keeps autoselecting function name as I type!