Eclipse Galileo

Hello everyone,

The latest version of Eclipse is out :) Codename : Galileo. So be sure to grab it on : http://www.eclipse.org/
If You’re on Mac OS X : Leopard, You will prefer the Cocoa version of the IDE :)

Then, let me give You a little tip : if You’re on Mac OS X, and even if You’ve setted up the JDK 1.6 by default, Eclipse won’t recognize it, and will still use the JDK 1.5. So to change that, go to the Preferences of Eclipse and then to Java, Installed JREs. You should be there :

Image 1

So click on the Add button. In the new window, select MacOS X VM as JRE type. Click next and now enter something like this in the JRE Home text field : /System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Home
Right, You’ve done the most tough part of it :)
Enter an explicit name like JRE 1.6 for example and hit the Finish button. Now You just have to select the new JRE in the list.
Now under the Installed JREs node, select Your execution environment as shown bellow :

Image 2

Well, it will soon be ok :) Just setup the compiler now. Go under Java, Compiler and select 1.6 in the list, as shown bellow :

Image 3

That’s all :)
Enjoy.

Java update on Mac

Hello everyone,

June, 15th 2009 : Apple released an update for Java on Mac for Mac OS X Tiger and Leopard : http://bit.ly/3NRDS.
This update brings more reliability, security and compatibility with Java SE 6 and previous version. But the thing I appreciate is the availability of the skin Nimbus (released with the Java 1.6 update 10 on others platforms) on Mac OS :)
I like this brand new skin Sun made some month ago. So now, You can set this skin up for your Java application.
If You don’t know how to do that, look at this, it’s pretty simple:)

For example, set the skin, directly in the main method, before creating any Swing component (JFrame, JWindow…)

try {

// Try to set the Nimbus look’n'feel
// You have to do it in a try block, in case the skin isn’t found
UIManager.setLookAndFeel(“com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel”);

} catch (ClassNotFoundException ex) {
} catch (InstantiationException ex) {
} catch (IllegalAccessException ex) {
} catch (UnsupportedLookAndFeelException ex) {
} finally {

// Start your GUI. If the skin isn’t found, the default one is used

}

Follow

Get every new post delivered to your Inbox.