 |
The beautiful World of Java Swing
Posted by alexanderschunk on November 10, 2007 at 12:32 PM | Comments (3)
Somewhere deep down in the API forrest...
In the beginning there was Swing as a subset of AWT with a huge array of features for GUI programming. Ok. Now we have JavaFX, Swing-X, Fuse and the Swing Application Framework.
Now, from the developers point of view its nice to have this kind of choice of many APIs available for GUI programming yet whats missing is a kind of overview what API to choose for what kind of project. For example the Swing-X API offers some features one would like to see in the Java Swing API. JavaFX has even more features not available in Swing and other such APIs.
If JavaFX is the next generation GUI API for Web and Mobile apps whats going on with Java Swing on the desktop?.
Bookmark blog post: del.icio.us Digg DZone Furl Reddit
Comments
Comments are listed in date ascending order (oldest first) | Post Comment
-
Alex,
What still comes to my mind regarding Java Swing is:
1) more control
2) more scalability - (depends)
3) still one language
4) maturity level, and many third party libs.
5) great look and feels
6) native desktop integration
To answer the question "whats going on with Java Swing on the desktop?"
In my opinion the future of Swing is going to be High Level Frameworks.
I still think they both have a great place in the spectrum of UI development. At this point it is still in the early stages of JavaFX and it will continue to mean different things to different people (like SOAs). Some people think JavaFX is like Flash (browser based). Some people think JavaFX it is an architecture for SVG, cell phones, etc.. Sometimes, while learning JavaFX I think of it as way to create Java Rich Client Applications in a Flash like way. (I really don't know how to program in Flash by the way) , but to most folks they see Flash as something that is embedded in your Browser and not a client side application. With the new and fast consumer jre, wouldn't Applets make a possible comeback and compete again with Flash? I think that's one of the major reasons why Flash was able to be so popular.
I'm just glad to know that there are two ways to develop UIs for the desktop using Java technology. I think it would be nice if we could simply create a mental Venn diagram with concrete examples of projects that would use those APIs on either side or both.
Some examples would be:
1) Forms based business application.
2) File sharing apps like Lime wire.
3) Chat programs
4) jogl like game like Jake
5) bejeweled, tetris, type games
6) Photoshop like applications
7) JMF type applications video player
8) Flash like car web sites
9) Another browser (just kidding...)
10) Skinable Winamp type apps
I hope Sun and/or the community can create some killer app to generate a lot of buzz like the days when cool Java games Applets were appearing everywhere.
As JavaFX is taking an approach like open source, which is a great idea, however it can still be perceived in a negative way. I still believe people view open source as incomplete, unpolished, large learning curve, and (you get what you pay for, so you settle - mentality). With more and more people getting rid of dial-up in exchange for broad band the demand for richer clients will increase which will be a certain inevitability. Oh, I forgot cooler and better cell phones too.
JavaFX maybe the next generation, but Swing is still in my opinion my main choice for large desktop applications to develop on. I don't think it would be wise to rewrite NetBeans in JavaFX (I could be wrong, I've seen weirder things).
Carl
Posted by: carldea on November 10, 2007 at 06:54 PM
-
Having recently created a few WinForms applications, I can confirm that Swing is an absolutely excellent API. It offers much more flexibility in terms of models (don't underestimate MVC), easy ways to override painting, and layout managers are great. The learning curve for Swing is perhaps a little high, but visual designers are getting there, and the JavaFX platform helps too.
WinForms offer a wider initial range of components, but with less flexibility (all parts of MVC are pretty mixed up). It's annoying to do dynamic layouts, draw single-edged borders and such like, and when you try to push it you often hit artificial limits. The next-generation XAML-based technologies might well change that again.
- Chris
Posted by: chris_e_brown on November 12, 2007 at 12:47 AM
-
I personally think that JavaFX will be a great tool for developing web apps and / or mobile apps.
Regarding WinForms, i can easily port a Swing application to .NET by regarding some of the .NET pecularities. One thing people forget when working with .NET is that you have to dock GUI components because otherwise you run into what i call the "maximize bug" - the WIndows app does not fit the components to its window size.
Posted by: alexanderschunk on November 12, 2007 at 03:08 AM
|