Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Essentials Java GUI building blocks? I.e. libraries to form a framework on top of Swing

Swing provides the basic building blocks for any GUI application but what about a higher level take on building GUI applications?

I'm not asking about the many arbitrary libraries that provide yet more wizzy variants on various visual components.

I'm talking about the missing pieces that everyone ends up building themselves whenever they create anything other than a trivial GUI application.

I.e. the framework that the application specific logic builds on.

E.g. handling data binding, application lifecycle issues or supporting common things like building forms.

If we were talking about persistence you could say that anyone can code up their own persistence layer using the javax.sql or java.io classes - however most people would rather use something like Hibernate.

So, just as someone asking about persistence libraries probably isn't looking for variants on ObjectOutputStream, I am not looking for variants on some JComponent subclass or other.

I think this is a fair Stackoverflow question as, unlike areas like persistence, a clear consensus on the answer is not easy to determine using Google.

Rather than a grab bag of random libraries perhaps people could answer in terms of what GUI issues are not immediately addressed by Swing and what libraries they feel best fill these gap?

I asked a similar question to this last week and it was closed - I've tried to phrase this such that this won't also be closed. If you feel inclined to close it perhaps you might consider making it community wiki instead?

like image 679
George Hawkins Avatar asked Feb 02 '11 18:02

George Hawkins


People also ask

What is Swing GUI in Java?

Swing in Java is a lightweight GUI toolkit which has a wide variety of widgets for building optimized window based applications. It is a part of the JFC( Java Foundation Classes). It is build on top of the AWT API and entirely written in java. It is platform independent unlike AWT and has lightweight components.

Does Java have a GUI library?

Java's original GUI library was the Abstract Window Toolkit (AWT). Swing (Chapters 12 and 22) was added to the platform in Java SE 1.2. Since then, Swing has remained the primary Java GUI technology.

What are the GUI components in Java?

GUI Component classes, such as Button , TextField , and Label . GUI Container classes, such as Frame and Panel . Layout managers, such as FlowLayout , BorderLayout and GridLayout . Custom graphics classes, such as Graphics , Color and Font .


2 Answers

Here are some essential libraries:

JGoodies - http://www.jgoodies.com/. This provides some nice layout tools (FormLayout) as well as common builders and databinding tools

SwingLabs - http://www.swinglabs.org/. This provides many common components you likely may need to use that are not part of standard swing.

Swing Application Framework - https://appframework.dev.java.net/ (already mentioned by jluzwick)

Groovy SwingBuilder - http://groovy.codehaus.org/Swing+Builder. This provides for easier building of GUIs by using a logical, hierarchical scripting-like language for building GUIs. It also has native support for some databinding.

like image 186
Jeff Storey Avatar answered Oct 22 '22 16:10

Jeff Storey


Could you be referring to something like this?

https://appframework.dev.java.net/

This was integrated with Netbeans at one point and I don't think the development has continued, but this framework greatly helped me in creating a much more involved application with java.

EDIT:

It seems these projects are derivations of the former I mentioned that are actively in development:

http://kenai.com/projects/bsaf/pages/Home

http://kenai.com/projects/guts/pages/Home

like image 3
jluzwick Avatar answered Oct 22 '22 16:10

jluzwick