Strange behaviour of open project window in netbeans - java

I've some strange behaviour when trying to open project in netbeans 7.3.1. The names of files/folders aren't fully displayed... You can see in attached image:
does anyone know what's happening? I need to use that particular version, so moving to the newest isn't possible in that case.

Related

weird icons beside my java project classes

I have opened my project today and I noticed some weird icons beside my classes as in this image :
I don't know what that means !
when I run my application it works great, and I get no exception.
how can I resolve this issue
If you're using a Source Code repository like SVN or CVS (you might have checked out this project out of some code repository) your recent changes must have made your local workspace go out of sync.
By using different colour codes and icons, Netbeans is simply trying to inform you which of these files are in conflict with the repository and need to be merged.
Some of the other icons could simply be informative like that "play" sign on your .java files indicates that the file contains a main() method and can be executed.
You should not be scared at all, the IDE marks the different file types with different icons. Most of the IDEs have similar functionality.

UI changes done in Netbeans do not reflect in Eclipse

I am mainly using Eclipse for my project. For Swing GUI part, I find using Netbeans is more user-friendly. Hence, only for building UI, I am using Netbeans for the same project.
I developed a form using Netbeans. So, corresponding .java file got generated in Eclipse also. After working on it for few days, I went to Netbeans and changed name of a JPanel. But, the same change is not reflected in corresponding .java file in Eclipse.
Before this, I have done such changes in Netbeans and even have seen the changes getting reflected in Eclipse version of the project. But, I don't know what went wrong this time. I even tried refreshing, cleaning etc.
Can anybody please help me with this?
Thanks!
Finally, I had to delete everything from the workspace and checkout everything again. After that, it is working fine.

Eclipse not creating new .java file in New Project wizard?

OK, I have a really basic (read stupid) question. I am just beginning Java programming, and am using Eclipse 3.7.2. I have done a few beginning projects without any problems. All of a sudden, when I create a new project using the wizard, it is not creating the src/.java file. When I try to manually add it after creating the project, I end up getting some cryptic error messages.
I have re-followed several walk-throughs on project creation for clues as to any option I may have accidentally un-checked and no luck.
Googling the answer brings up results for more advanced problems that are unrelated.
I have combed the preferences, but nothing looks obvious, and
I have gone hunting for any user app data I could delete to force a clean slate.
I have even created a new instance of Eclipse to a different directory and still have the same result.
My son's instance, which is on the same computer still creates the .java file from the wizard. The only difference is that my instances have the Android SDK installed (I am trying to create basic Java projects and not Android projects).
I am at a loss, and have lost a lot of time trying to correct the situation. What do I need to do to reenable the creation of a src/.java file in Eclipse?
Screenshots (click on image for full size):
Make sure you are choosing a java project from the right folder in the wizard. It sounds like it is creating an android java project, which is probably why your src folder is missing. See if there is a helloworld project under example projects too in the wizard, that may get you started too. Screenshot may help us. I want to see which project type you choose and which folder it is in.
How about changing eclipse to point to a new workspace. That may drop the android settings. Under the file menu, choose switch workspace and pick a new location. Thats most likely why a new install did not fix it. That workspace may have android settings in it, so change to a new folder somewhere else to test it like c:\workspace2\
Here's a good tutorial I found that may help too.
eclipse java project tutorial

Source code navigation and JavaDoc bug in Eclipse Indigo

I have a problem with Eclipse Indigo regarding library source code. When I open a library class (e.g. from the JDK, but also from some other included libraries, such as Guava), either using the Open Type dialogue or simply through Ctrl+ click on the class name or some of its methods, once in a while (not always) something breaks.
Don't get me wrong, the source is always displayed without any problem (either JDK source shipped with the JDK itself or Guava source downloaded by Maven). What actually stops to work:
When I open the Quick Outline popup in that given class using Ctrl + O, the list of methods and fields displays normally, but when I click on any of them, Eclipse doesn't move the view on it as it should. Also Ctrl + clicking any of the methods or fields of that class in my code doesn't bring me directly to it, but simply at the top of the source file.
When I hover over that said class or its methods, no JavaDoc appears in the popup as you can see in the attached image. I am in the HashSet class, the source is clearly there, but it isn't displayed in the popup.
I found out that this can be fixed by opening the Outline View and briefly clicking through the class's methods and fields. After a few clicks, Eclipse catches on and starts to work correctly, but only for this one class, not for all which are broken in this way at the moment.
Has anybody met this kind of bug? Is it tracked at Eclipse Bugzilla? Thanks in advance for any advice.
For completeness, this is my configuration:
Windows 7 Professional x64
Oracle JDK 1.7 Update 2 32b
Eclipse Indigo for Java EE Developers 32b
your issue #2 may be resolved by following these steps :
Go to http://java.sun.com/j2se/1.5.0/download.jsp and choose to
download the JDK 5.0 Source Code.
For JDK 5.0, select Download(SCSL source).
Download JDK (SCSL) 5.0 (1.5.0). This will give you a file jdk-1_5_0-src.scsl.zip. You do not need to unzip this file; Eclipse likes it the way it is.
In Eclipse, go to Projects -> Properties -> Java Build Path -> Libraries and expand JRE System Library [jre 1.5.0], then rt.jar. Select Source attachment and click Edit...
Select the above zip file. and Finish by exiting the dialog boxes.
source
Hope this helps..
Sounds like wrong sources are attached to the libs inside Eclipse.
I had similar symptoms in a project where a class exist in both: inside a lib and in the project's src folder. Same canonical class name, but different implementations.
I would recommend to verify (or reinstall) your JDK-Installation and re-configurating it in Eclipse.
Hitting Ctrl+Shift+T and typing HashSet and taking a screenshot of that window may help here, too.
To answer my own question, I didn't find out how to solve the problem in Indigo, but updating to Juno fixed it.

Error symbol not shown in Navigator view

I use Eclipse for java development:
Eclipse Java EE IDE for Web Developers.
Version: Indigo Service Release 1
Build id: 20110916-0149
Currently the Navigator view does not show the small error symbol (white x on red background) if there is a syntax error within the file.
I tested this with a small java project with a single java class. An intentionally created syntax error lead to an entry in Problems view and an error symbol is shown in code view, in file tab and in Package Explorer, but not in Navigator view (neither file level nor folder level).
"Build automatically" is activated.
Any ideas how to display the error decorator also in Navigator view? Is it a bug maybe? Thanks!
Imo, that's a bug. It, actually, appeared with SR1. If you reinstall the vanilla Eclipse Indigo - the error decorator would come back. It would be great, if they'd fix it, as currently it's quite annoying...
EDIT: Oook, so, oficially, it's not a bug. The intended behaviour of the Navigator view is to not display any markers related to Java code validity. The previous (long standing) state of affairs was a bug, and was fixed by this bugfix: https://bugs.eclipse.org/bugs/show_bug.cgi?id=291498
Unfortunately (imo) this, apparently won't change as this bug report ( https://bugs.eclipse.org/bugs/show_bug.cgi?id=364660 ) was closed with RESOLVED WONTFIX.
The official suggestion is to use either Package or Project Explorer views. From my attempts to live with Project Explorer it's still not as convinient as the Navigator was, although it can be tuned to be rather close to Navigator.
I've also tried to feed Eclipse 3.7.1 with the Navigator bundles from the previous 3.7.0 release. While I'm not 100% sure it's a good solution it worked for me.
I think this is the normal behavior. I don't think it can be modified.
I am still working with Eclipse Helios and observed the phenomenon (=no error indications) in package explorer (sic!) after removing all entries in the "problems & warnings view".
After removing the tab displaying the list of errors across all sources, the indicators reappeared again.
For me that's clearly a bug, though only a quite minor one...

Categories

Resources