I have been working with the Swing library for a long time, I'm working on a new project for school and due to the nature of the program it can't look like a generic/boring swing gui. So my question is does anyone know of an interesting java gui library that is not swing or awt?
I think that SWT/JFace (come with Eclipse but can supposedly be used standalone) are well designed and more interesting to use/learn. For example, JFace follows sort of an MVC approach.
If you think that Swing produces boring UIs then you really need to get this book: Filthy Rich Clients.
I don't think you need to look at different GUI libraries, I think you need to look at different Look & Feels, I quite like Synthetica, plus some of their Look & Feels are free for non-commercial applications.
Well, if you use Java 6u10+, you can use the new Swing GUI option, Nimbus.
UIManager.setLookAndFeel("com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel");
You can also try Java Scenegraph "standalone" (ie. using only java + scenario, not javafx). But its documentation is not very good. Here's a code sample, using the scenegraph 1.0 ("Scenario.jar" shipped with JavaFX).
import java.awt.Color;
import java.awt.Paint;
import java.awt.geom.Point2D;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
import com.sun.scenario.scenegraph.JSGPanel;
import com.sun.scenario.scenegraph.SGGroup;
import com.sun.scenario.scenegraph.fx.FXText;
public class HelloWorldScenario101 implements Runnable {
/**
* @param args
*/
public static void main(String[] args) {
SwingUtilities.invokeLater(new HelloWorldScenario101());
}
public HelloWorldScenario101() {
//
}
@Override
public void run() {
this.frame = new JFrame();
this.panel = new JSGPanel();
this.text = new FXText();
this.paint = new Color(255, 0, 0, 255);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setTitle("Hello World");
frame.add(this.panel);
frame.setContentPane(this.panel);
scene = new SGGroup();
this.text.setText("Hello World");
this.text.setFillPaint(this.paint);
this.text.setLocation(new Point2D.Float(10, 10));
this.scene.add(this.text);
this.panel.setScene(scene);
frame.pack();
frame.setLocationByPlatform(true);
frame.setVisible(true);
}
private JFrame frame;
private JSGPanel panel;
private SGGroup scene;
private FXText text;
private Paint paint;
}
I would strongly suggest Qt Jambi if it wasn't discontinued. You can check out the demo to see what your application will look like.
I am still waiting to see how the community driven effort will evolve before deciding to abandon it but I wouldn't start something that matters to me in Qt Jambi right now, but I think that it would be a good fit for your situation.