X
  • May 24, 2015

News from the Modular JavaFX Application Framework

Geertjan Wielenga
Product Manager

The last time I reported on the status of the mFX project was in July last year.

The biggest problem at that time was that the mouse didn't work on the menus. I ran the project again today and I guess my JDK is different (newer) than what I was using at that time because now that problem is fixed, without any changes in my code, i.e., something has been enhanced on the JavaFX level.

Click to enlarge the image below to see a JavaFX application on top of mFX:

The remaining problem is that the window system is still in Swing. If the tabs could somehow be rewritten to JavaFX (and I have tried several things without success) then the entire application would be stylable via CSS.

Aside from that, it's looking pretty good. Above, you see a CSS-styled label that updates itself, via NetBeans Lookup, based on whatever the user has chosen in the selector window in the top right. There's an editor module, a viewer module, and a domain module, in other words, mFX truly enables you to do modular JavaFX development, using all the techniques provided out of the box by the NetBeans Platform, i.e., modularity, loose coupling, and pluggability.

Join the discussion

Comments ( 7 )
  • alex Monday, May 25, 2015

    I can add to the rough edges: the aliasing on the styled tabs is pretty pronounced (yet somehow the fonts that say Tom are antialiased very nicely). The elipsis button in the lower right pane looks decidedly Swing.

    JavaFX is coming along nicely, but, as someone who remembers the transition from AWT to Swing, I can't shake the feeling that a lot of these rough edges should have been smoothed out before 1.0.


  • Geertjan Monday, May 25, 2015

    The tabs have nothing whatsoever to do with JavaFX. They are Swing, did you miss that when I said "the window system is still in Swing"?


  • Geertjan Monday, May 25, 2015

    And, yes, the bottom right panel is, in fact, completely Swing.


  • Steven Yi Monday, May 25, 2015

    Hi Geertjan,

    I checked out the source from https://svn.java.net/svn/mfx~src and tried to run the project. I get a message that the modules have been loaded, then the application freezes with a beach ball. I'm on Mac OSX 10.10.3, jdk1.8.0_45. This is happening both by running the project within the IDE, as well as building a Mac OSX Application and running that outside the IDE. I tried debugging the app and stopping execution to see if it would land somewhere and maybe show an infinite loop but I didn't get anything from that.

    Have you tried this on Linux or OSX?

    Thanks!

    steven


  • Geertjan Tuesday, May 26, 2015

    Will take a look on Mac OSX when I get a chance to do that in the next few days.


  • alex Wednesday, May 27, 2015

    I didn't miss "the window system is still in Swing", but I assumed you were referring just to the main window and the fancy tabs were JavaFX. My bad.

    That being said, AA can be enabled in Swing, but it seems to be off here, while JavaFX is doing AA. Does that mean there are different, independent AA settings? Or is JavaFX always doing AA (because I can't seem to remember reading anywhere of a way to control that).


  • alex Wednesday, May 27, 2015

    Ok, so there's scene and shape level AA in JavaFX. Clearly a whole different approach so it makes sense they're controlled independently.


Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.Captcha
Oracle

Integrated Cloud Applications & Platform Services