Some of my favorite things about the JavaFX SDK Preview



I’m sure you all saw that our JavaFX team released a preview of the SDK at the end of July. I’ve been happily tinkering with it for the last few days. If you are hacking with AJAX, moonlighting with Silverlight, or fumbling with Flex, I think you should get up close and personal with it too, and see what its all about.

We’ve been talking about JavaFX in various ways for some time now, so you probably already know that its for building rich client applications, that it itself is built using Java, and that it will span multiple devices - from small mobile phones through TV settop boxes to the PC desktop and browser. Most importantly, if you are a traditional Java programmer (I include myself), you will notice there’s a paradigm shift. A shift moving from the Java programming environment, whose generality spans quite an astonishing range of applications, to a programming environment specially designed for those amongst us with more developed visual design skills than technical ones (sadly, I cannot include myself). Those who are focused on one kind of application: interactive and fabulous looking.

Looking ahead a little, the plan here is to release the final version of the SDK for the desktop at the end of this year and a preview of the mobile version next March or so. I say or so, not just because schedules are schedules, but because we are ready to adjust based on the feedback we get from this preview release.

Anyhow, some of my favorite things about this preview release are:-

The Language: JavaFX Script

Described in full in the language guide included in the SDK, this new language is highly declarative (i.e. it says what its going to do, rather than saying how to do it), with features like data binding to let you to bind one variable to another variable. Like,

let oneVariable = bind anotherVariable;

(I did say it was declarative). Or like the triggers feature, so that when the value of one variable is replaced, you can have something else happen at the same time.

attribute oneVariable
    on replace doSomethingElse();

To a Java programmer its going to be an easy new language to pick up because it shares much of its syntax with the Java language. To a designer, its going to be an easy new language to pick up because its clean, straightforward and does on the screen what it says in the code. And it has no baggage to carry.

The APIs

Neatly divided into two profiles (which you can see here) - the common profile for all the APIs that will be available on every device, and the desktop profile for all the APIs that make sense only for applications on a desktop. There’s a mobile profile to come of course in the mobile release next year, which will have the common profile plus APIs that make sense on mobile devices.

As part of the common profile, you have the scene graph and the media JavaFX APIs. The GUI of an application is modeled as a graph of visual nodes, (each node being a shape, line, piece of text, GUI widget or embedded media), that moves, twists, rearranges as the user interacts with it. The scene graph API in JavaFX is especially well suited to the transition effects and animations that make all the difference between a user experience and a captivating user experience. The media supported in the scene graph includes a player control and support for OS native formats. You’ll remember we inked a deal with On2 to provide cross device media support in May. Well that will have to wait a little longer before we can put that in. But we’re all crossing our scene graph nodes that it will be soon.

The desktop profile includes the common profile, plus some desktop specific extras like…many of the tried and tested Swing widgets we know and love: buttons, combo boxes, lists and so on. So no shortage of the basics you need there.

And of course, being built in Java and on Java, you can always reach down into the underlying Java APIs for your favorite Java API if you would like to use that in your application too.

NetBeans integration and Project Nile Plugins

Naturally, the SDK is available pre-integrated with NetBeans 6.1 which is how I’ve been looking at it, as have others. The language and APIs are supported in the IDE with all the things you would expect like syntax coloring and checking, debugging and so on. Together a tutorial and a range of samples. The samples are generally short and to the point. Want to see how to draw polygons ? There’s a sample just for that. Want to see how to use keyframe animation to bring life to randomly moving particles ? There’s a sample just for that. Transparency, color gradients, bounce a ball ? Check, check, check.

Also included in the SDK is a collection of plugins (codenamed Project Nile) to Adobe Photoshop and Illustrator so you can keep working on the art there, and use Project Nile to export it into your JavaFX application and bring some life to it.


My other favorite thing is that this is all running on Java SE. So applications created in JavaFX aren’t just running on any old VM, its running on a supremely stable, scalable and high performing runtime. But I don’t have time to tell you about all that just now.


There’s more to the SDK than just my favorite things. If you’ve been curious about JavaFX, now is a good time to take a look for yourself.


Thank you for your interest!

We will contact you as soon as possible.

Send us a message

Oops, something went wrong
Please try again or contact us by email at info@tikalk.com