I would like to ask your opinion[s] about how to approach the problem of generating Swing application UIs at runtime. And, to start: I am writing a Swing client application - not an applet and not a browser-based application.
My IDEAL user experience would be to simply display DHTML in something like a JEDitorPane - but that doesn't work because
1) my UI is fairly complicated (perhaps too complicated for a JEditorPane) and
2) more importantly, JEditorPanes do not handle JavaScript. Thus, there is no way for the application to interact with the UI elements (e.g., to highlight a button or to get an indcation that a checkbox was clicked).
I've looked at LOBO/COBRA, but the COBRA library does not render pages well [yet?]. It certainly is not up to what one sees in a regular browser.
I looked at Flex from Adobe, but I'm concerned about the deployment of AIR. I don't have any data as to how widely it's deployed versus JVMs.
So I'm pretty much resigned to just using normal Swing controls , perhaps modified with a better skin/look and feel than the default. What I need to do is to be able to generate the UI at runtime by reading a set of directives - XML, for example. I thought JAXX would do the trick, but it appears that JAXX is really a tool for implementing controls and their wiring at compile-time and not what I'm looking for.
I've seen the documentation for XUL, but I don't see any classes or libraries that can read and parse XUL and create Swing controls at runtime.
So, I want something fairly lightweight, easy to use, open-source and fairly well maintained. I've scoured the web looking for a solution and have found none and I'm almost resigned to writing my own runtime system to read and parse XML and then execute code to create controls on the fly...but this is not a trivial task.
It seems to me that with the advent of rich client UIs, I can't be the only one facing these issues. Does anyone have a suggestion? Am I missing something?
Thanks!