Java on the Desktop, the past, the present and the future – interview with Richard Bair
December 5th, 2008 | 13 Comments »In this interview Richard Bair answers my questions on Swing, SwingX, JavaFX and Java on the desktop in general, saving some of the announcements for the next week’s Devoxx conference. We wanted to do this interview immediately after my thoughts on the state of core Swing, but the JavaFX release has postponed it up until now.
Tell us a little bit about yourself.
Like many developers I know, I started programming because I wanted to write games. Somewhere along the line my dad convinced me to write him a database backed application for his business, and that’s how I got started.
Since then I’ve been predominantly an application developer. It was in that role that I started working with open source software, and eventually started working with JDNC. I was subsequently hired by Sun and have been the SwingLabs lead since that time.
It hasn’t been all smooth, I learned a lot about open source community building as I went along, and certainly have plenty of faults in getting SwingX releases out regularly. But my overall goal and desire has always been to make building real world applications easier.
I know in the recent past I’ve been involved a lot in Java demos and such that are consumer in nature. I like building applications, either consumer or enterprise. Consumer applications are closer to what got me started in programming in the first place, while enterprise apps are really where I cut my teeth (one of a handful of engineers I’m sure who love both big iron databases and pushing pixels ;-)).
Why was SwingLabs created, how did it evolve and what is its current state?
SwingLabs was a bold attempt by the Java Client Group to engage the open source community long before OpenJDK came along. Originally the brainchild of Amy Fowler and Hans Muller (and probably others on the team), the idea was to have an open source venue for building APIs that fill in the missing pieces of what is shipped with Swing.
As any Swing developer can attest, you have to build a lot of plumbing to build real apps with Swing today as shipped with the JDK. In the last few years a great many open source projects have been created to help fill these gaps.
SwingLabs was also designed as a place where these APIs and experiments could be vetted and included in the JDK. Our score in this regard is not so good. We pulled in a lot from the JDIC project, and we pulled some of the filtering and sorting work in.
We will be pulling more for JDK 7 as well, expect to see 2 or 3 components at least and also one or two big JSRs.
SwingLabs is currently run predominantly by the community which is really working I think pretty well. The dedication of our team of open source developers is a credit to them and to the open source reality that we live in.
We do need more involvement from the Sun side, and will be making an announcement in this direction at Devoxx next week.
If you were to start over with SwingLabs / SwingX, what would be the most important parts in building and maintaining the community involvement?
Regular releases. Regular content added to the SwingLabs.org website. More responsive bug fixes (my fault entirely).
Would you like to provide your side of the story behind the decision on the layers and painters in SwingX?
The fundamental idea behind painters was to decouple the rendering of components from the components themselves, such that you wouldn’t have to subclass the component to change its rendering (or replace its LAF which is a much more complicated proposition). The corollary was that there could be a collection of default painters that people could reuse.
There was an argument made primarily by Mikael Grev who had a similar API in his MIG Calender component (if I remember correctly) that we should have components that support painters to have an arbitrary sequence of painters. Sort of like JLayeredPane but for painters. I know Scott, Romain, Josh, and I didn’t particularly like it for technical reasons (which are all documented in the forums), and there was both support and skepticism from other people outside Sun.
At the end of the day, the project lead has to make a call on API, and I made the call I felt most comfortable with.
How likely is it to see the SwingX components being part of core Swing in JDK 7 and beyond?
All of them? Unlikely. Some of them? Extremely likely.
Originally Nimbus was planned to be developed under the SwingLabs roof, but was later put into the internal repository. Would you like to see the development of new Swing-specific functionality in the open before it gets put into the core distribution?
Nimbus is a special case. To properly implement Nimbus required a significant number of fixes and enhancements to BasicLookAndFeel, Synth (lots of bug fixes for Synth) and other core APIs and implementations. We simply could not have delivered Nimbus in the open source without these fixes. Also, Nimbus went into Java 6 Update 10 which was not part of OpenJDK. When Nimbus is forward ported to Java 7, it will be in OpenJDK.
I would prefer that all development was done as part of a community process, be it SwingLabs or an open JSR or OpenJDK.
Do you think that maintaining backwards compatibility has unnecessarily restricted the Swing team in moving this UI toolkit forward?
No I don’t. If you gave up backwards compatibility you’d have a whole other set of issues that are many times worse. The level of risk one developer is willing to take isn’t the same as another. For every one person who wishes we’d ditch backwards compatibility there are another 50 that would be violently opposed when that advice rendered their applications (or development of future versions of their applications) inoperable. Especially with a technology as mature as Swing.
To those people who say we should make a Swing2 which is not backwards compatible, I would say, this is exactly what we’re doing with JavaFX.
I also want to emphasize that Swing isn’t going away. We have a tremendous number of customers building Swing apps and that will obviously be supported and extended going forward. Also, we will allow you to mix JavaFX both into Swing apps and mix Swing in JavaFX.
Both Microsoft and Adobe view “line of business” applications as a very important target segment for their offerings (WPF, Silverlight, AIR, Flex). Is JavaFX only targeting the rich UI development (graphics, effects, animations), or do you plan to include modern business components such as pivot tables, grid trees and date pickers?
JavaFX 1.0 is oriented toward creative content, very similar to Silverlight 1.0. Future versions of JavaFX will be designed to also handle full blown enterprise rich client application development.
What effort is planned to be put into the core Swing in 2009?
We’ll have announcements for these plans at Devoxx.
Anything else you would like to add?
As an application developer, and as a toolkit developer, JavaFX is very exciting for me. The first release is really aimed at providing the foundation for all subsequent work. We’re focusing on animation, graphics, media, and related APIs with an eye towards the future so that we have a solid foundation upon which to add user interface Controls, frameworks etc. JavaFX gives us the freedom to design the best possible design we can, without any API backwards compatibility constraints. It really is an exciting opportunity. We’re committed to providing interop between FX and Swing so that people can build the kinds of applications they want to, and can mix and match the two.
Related posts:
- Java desktop spotlight – interview with Sam Berlin of LimeWire I’ve talked about LimeWire in the latest installment of Swing Links of the Week, and...
- Java desktop spotlight – interview with Elie El Khoury of Woopra Woopra desktop client is my favorite Swing application of the year, and it’s time to...
- Is one of my Java desktop 2008 wishes coming true? I had only two things on my Java desktop wishlist for 2008 – cross-platform support...
- Java on the desktop I’ve said before that the customers don’t care about the technology. To a certain extent,...
What I’d like to see:
. a new set a components in JavaFX 2.0 (alongside the great Flash-like graphical tool you’re coding right now :) )
. many samples on how to use in plain Java any JavaFX functionality (including those future components)
. closures and properties (with binding) in Java 7 (8?) without calling it Java-the-Language-FX to remove any backward compatibility constrain (or rename it anything you like but keep the syntax)
. the Yahoo Toolbar and the default tray icon gone (so important)
In fact, we want Swing2 (with painters) without JavaFX Script (which may be great…I guess)
And please…look at the Flex 4 demos on how to skin an app.
And…congrats for this JavaFX release…I like the “Actionscript then the graphical tool” approach.
Kirill,
Do you have links to the forum threads referenced above regarding the discussions on Painters? I’m interested in reading them, but would like to avoid hunting around for them!
-Ken
This is the most important thing (freedom = evolution):
JavaFX gives us the freedom to design the best possible design we can, without any API backwards compatibility constraints
Please also include something like a Form “component”.
Speaking of Nimbus, now I fixed my headless JTable bug it works ok and it is better than many L&F but still is not up to the quality of JGoodies Looks – I hope Sun is sponsoring Karsten to continue his good work. I know as soon as I can afford it I will be.
Ken – the links can be found in the blog entry linked in the first paragraph.
One other thought – Richard should not take the criticisms of Sun and Swinglabs to heart. Swing is a mature and quite awesome toolkit.
Between Swing, JBoss and Hibernate I have been able to focus my open source project on business requirements for a while now – rather being bogged down with technical plumbing issues.
With Nx I can then put the rich application on Amazon and you have a very fast (even over low bandwidth) and very stable application that does not vary from browser to browser – and only requires a 60 second install of the NxClient.
I do not find Swing lacking – any issue I hit I can google and find the answer – or occasionally post and get a reply in 24 hours.
I love how I can build custom controls suited to specific UI requirements – its very powerful. Most of the issues people have with building large applications I think are not due to lack of JSR’s or documentation, I think the issues are general architecture issues applicable to most toolkits. IMHO.
About Swing and SwingX…
If you are interested into Swing, SwingX, JavaFX, you shouldn’t miss latest Kirill’s interview of Richard Bair. Let me just point out a couple of passages:How likely is it to see the SwingX components being part of core Swing in……
Wow. I must say I am so impressed with javafx’s first release. Well done sun… we knew you had it in you!!!
Well, to me it seems, JavaFX is a nice start, but nothing more. Effectively Mr. Blair already states it when he says “JavaFX 1.0 is oriented toward creative content, very similar to Silverlight 1.0″.
If JavaFX 1.0 is comparable to Silverlight 1.0 (and I would second that opinion), then this basically means that Sun is about two years behind its competitors (Microsoft with Silverlight 2 and Adobe with Flex 3).
Furthermore I miss a general strategy for Desktop+Web-Development for JavaFX. Microsoft has the WPF+Silverlight duo and Adobe has Flex and AIR.
With Sun I now see JSP, JSF, Swing, JavaFX plus SWT (whose existence is not directly Suns fault) and I am really missing some clear communication on the overall strategy for Java-UIs. As much as I like Java, I do feel embarrassed by the state of Sun’s UI landscape (not to mention the pain of styling UIs which is fortunately eased by Substance).
But well, we will see what rabbits Sun will pull out of their hat in the future. Maybe there’s really some JavaFX based UI components in it.
Best,
S.
[...] lectura muy recomendada acerca del Pasado, Presente y Futuro del Mundo Desktop en Java: http://www.pushing-pixels.org/?p=922 Enlace al oficial “Acerca de” de JavaFX: [...]
I too started programming so that i could write games I choose Java as core language and now i am so much tangled with business application that i can hardly give any time to write games.
After all java alone is not enough for making java
I tried SwingX, JOGL , JMonkey engine and few other api but never could render games as they do with other tools like mel(Maya) script or Microsoft directX.
Java is still best for writing for Mobile platform but till when i don’t know since flash and symbian are also making very nice moves.
I request all the IDE developers and JAVAFX developes to make development and deployment of JAVAFX application quick and easy.
and finally is there any way i will be doing 3d with JAVAFX. if JAVAFX supports 3d programming in easier way than FLASH (Flash astro, papervision , and away3d) and Silver light then i see many developers and designers moving towards JAVAFX from flash and silverlight
[...] Una lectura muy recomendada acerca del Pasado, Presente y Futuro del Mundo Desktop en Java: http://www.pushing-pixels.org/?p=922 Enlace al oficial “Acerca de” de JavaFX: http://www.javafx.com/about/overview/ This entry was [...]
[...] Una lectura muy recomendada acerca del Pasado, Presente y Futuro del Mundo Desktop en Java: http://www.pushing-pixels.org/?p=922 Enlace al oficial “Acerca de” de JavaFX: [...]