FX Experience Has Gone Read-Only

I've been maintaining FX Experience for a really long time now, and I love hearing from people who enjoy my weekly links roundup. One thing I've noticed recently is that maintaining two sites (FX Experience and JonathanGiles.net) takes more time than ideal, and splits the audience up. Therefore, FX Experience will become read-only for new blog posts, but weekly posts will continue to be published on JonathanGiles.net. If you follow @FXExperience on Twitter, I suggest you also follow @JonathanGiles. This is not the end - just a consolidation of my online presence to make my life a little easier!

tl;dr: Follow me on Twitter and check for the latest news on JonathanGiles.net.

JavaFX links of the week, November 28

A heap of interesting links this week, so I’m going to skip the introduction and get right into it. Enjoy! πŸ™‚

That’s all folks. Keep up all the great work and I’ll be back in a weeks time to cover everything that happens this coming week! πŸ™‚

JavaFX links of the week, November 21

Welcome to another week! πŸ™‚ There is a heap of good links this week – it seems the quality of blog posts is certainly increasing these days! Keep it up folks πŸ™‚ As always, I hope you enjoy some of the links below, and always feel free to email me links to include.

  • I mentioned last week that the ThingsFX Swing-in-JavaFX project didn’t support key events, but that it was coming soon. In actual fact, I was wrong – it is already supported.
  • Speaking of ThingsFX, one of the members of that team, Roman Kennke, blogged elsewhere about the Swing in JavaFX integration, and even put up a demo applet that shows the current implementation. As you’ll note, it is a little slow, but it shows a lot of promise once faster options are made available.
  • Tom Schindl has released e(fx)clipse 0.0.8, and now e(fx)clipse also has an official website. This project is very exciting, so if you are an eclipse user and want top-notch JavaFX tooling support, you should check this out and provide feedback.
  • Zonski continues blogging about his research and development with JavaFX 2.0. This week he talks about file downloading in JavaFX 2.0 (over HTTP).
  • Johan Vos has blogged about visualizing REST XML data in JavaFX controls, making use of the DataFX project.
  • Tom Eugelink follows up his JavaFX 2.0 bubblemark explorations after being told of a runtime switch for JavaFX 2.0 that removes the 60fps limit that JavaFX imposes.
  • The slide deck that Stephen Chin and Peter Pilgrim used at Devoxx 2011 for their “JavaFX 2.0 – A Developer’s Guide” session is available online for those interested.
  • Patrick Champion blogged about extending a JavaFX 2.0 control to add functionality. I should probably add that their are simpler ways to doing this in many cases, which I covered in a JavaOne talk called “Custom UI Controls and Charts with JavaFX 2.0“.
  • Andre Hogenkamp has posted a second blog post about running JavaFX 2.0 in Linux (whilst awaiting official support from Oracle).
  • Scott Hommel has blogged about using the JavaFX Screen API to determine the dimensions of the users screen.
  • Eric Bruno blogged about JavaFX 2.0 binding APIs. Whilst it is a good blog to cover the main concepts of binding in JavaFX, it skips over some simpler options that are possible for the specific use case mentioned in the post. For example, rather than bind the TableView width/height to the scene width/height properties (and place them inside a Group layout), if a StackPane is used instead the TableView will grow automatically without needing any bindings. Similarly, some controls have their max width/height set to the pref width/height, so it is simply a matter of calling, say, button.setMaxHeight(Double.MAX_VALUE) to have them grow automatically when placed in a relevant layout.
  • I’ve come across two JavaFX-related projects on GitHub that people may be interested in, but unfortunately no related websites for further details. Firstly, user ‘nahi’ has JRubyFX, and user ‘skrb’ has SVGLoader. Fortunately the project names are fairly self-explanatory πŸ™‚

Keep up the great work folks. Catch you all in a weeks time.

JavaFX links of the week, November 14

Here we go again – this week there are a heap of JavaFX links, so I’m just going to get right in to it – enjoy! πŸ™‚

Well, that’s it for another week. Hope you found something useful. Catch you in a weeks time! πŸ™‚

JavaFX links of the week, November 7

Another week, another round of links from the JavaFX world. I hope you all find something of interest. Enjoy! πŸ™‚

That’s all for another week. Keep up the great work folks and I’ll be back in a weeks time to highlight everything you’ve been up to! πŸ™‚

JavaFX links of the week, October 31

Here we go for another week! πŸ™‚ It seems the number of JavaFX links is really starting to pick up after JavaOne. The most notable news this week was that Oracle has started the open source discussion. Find all the details, and plenty of other interesting links, in this weeks JavaFX links roundup!

Hope you all enjoyed the links – catch you all in a weeks time! πŸ™‚

OpenJDK Discussion About JavaFX

I just sent the following letter to the OpenJDK community “discuss” mailing list:

Hi OpenJDK community!

As announced at JavaOne we (Oracle) would love to contribute JavaFX into OpenJDK as a new project called “JFX”. For some who have been following along, we’ve talked about this for a long time but finally (finally!) we’re ready to act on it and open source the platform. We are not just interested in open sourcing the code, however, we also want to move into an open development model. We already have an open bug database[1]. The project uses Mercurial, so we should fit in pretty well into OpenJDK.

Our basic motivation for wanting to open source JFX is to built a community and ecosystem support and adoption around JavaFX by increasing transparency. Of course we are also interested in getting patches and early feedback from the community[2]! Our goal is to provide the next-generation Java client toolkit, and JFX would be the next step along that path, which hopefully culminates in a JSR for the Java 9 timeframe and including JFX as proper part of the JDK. I would be the initial Project lead for JFX.

A little bit about our project:
It is a significant contribution to the corpus of open source code
It includes over 6000+ public API members (methods / constructors / etc)
It includes over 11,500 unit tests
Core libraries such as observable collections and binding
Scene graph, effects, graphics
CSS support for JavaFX
Media
WebView
Prism (hardware accelerated graphics, including openGL and D3D and java2D implementations)
Glass (windowing system, base porting layer, including mac, linux, and windows implementations)
UI Controls and Charts

Our builds are all Ant, with JUnit for testing (there is some ‘make’ in there for native parts). We also have NetBeans projects setup for each area. There is a lot of code that we’ll be releasing, so as a matter of practicality we’re going to release different parts of JavaFX over the course of the next few months, starting with UI controls followed by charts. We’ll put up a full roadmap onto our project pages, should we be approved to become part of OpenJDK. We’ll make sure that the open source code is always fully buildable by anybody using the sources + a binary plug (which will become unnecessary as we open source the remaining pieces). All of the above listed modules will be open sourced and fully buildable.

What do you think? I’d love to hear any issues and hopefully be able to resolve those prior to requesting an official vote.

Thanks
Richard

[1] http://javafx-jira.kenai.com
[2] A good example of the sort of interesting stuff going on out there can be found here: http://jroller.com/neugens/entry/embed_swing_inside_javafx_2

This is the first step towards open sourcing JavaFX into OpenJDK. First I wanted to talk with the community about it, and if it looks favorable, I’ll follow up with an official project proposal. Here’s hoping! If you are a subscriber to “discuss”, please go and throw in some good word for the idea and if you have any questions I’d like to hear those too. If you aren’t a member of “discuss”, go join :-). You can do so here.

It feels good to finally be getting this all out in the open source!

JavaFX links of the week, October 24

Having been traveling for the last three weeks, I’ve not been able to post the weekly JavaFX links roundup. Today I’m trying to make up for this by posting all the links I gathered as I was traveling (and on vacation). There are two problems with this approach: 1) what follows is basically information overload, and 2) I almost certainly missed links. I hope you can all forgive me for this one time, and I also hope you find a heap of interesting links in this post (it took me a looonnggg time to write this week!).

Whilst I’m here, I must note that it was great meeting so many people at JavaOne. The number of times I was speaking to someone who didn’t know me, only to see my name badge and know exactly who I was because of this blog was actually very impressive. I’m surprised so many of you read this blog! Anyway, with that (and because this post is already long enough) let’s get straight into it… πŸ™‚

Phew! That’s that for another week. I’ll get back into the regular schedule starting next week, so hopefully next weeks posting won’t be as great an ordeal (for you and me!) next week. Catch you all in a weeks time folks πŸ™‚

Introduction to DataFX

Introduction to DataFX

One of the projects I worked on leading up to JavaOne 2011 was the DataFX project, which, as I wrote on the website, “is an open source project that intends to make retrieving, massaging, populating, viewing, and editing data in JavaFX UI controls easier. It’s all that boring kludge work you have to do between getting user requirements and delivering a rich user experience.”

DataFX is a project Johan Vos and I have been working on for many months now, and it has gone through a number of iterations in that time. At JavaOne 2011 we put out a first release (let’s call it version 0.0.1 for lack of an official version number), and today I want to briefly introduce it for those of you who didn’t attend JavaOne. However, even if you didn’t attend JavaOne, we’ve put the slides online.

To be very clear, DataFX is not an Oracle project! Johan and I both developed this in our own time, and it does not necessarily represent the future plans of the official JavaFX project. This project was built to make many of the UI controls I develop easier to work with by filling in the gaps as of the current JavaFX 2.0 release. Oracle may or may not have future plans in the same area as DataFX, but for now DataFX exists to fill the gap. For more details, check out the DataFX FAQ.

To make things easier to understand let’s conceptually split DataFX into two sub-projects which attack a common problem from two different angles.

(more…)

Slides from JavaOne

I’ve just returned back from three weeks in the US, and one thing I was asked very frequently during JavaOne was if I’d be making my slides available. It turns out that I don’t even need to upload the slides manually this year – Oracle has put them all up online already. If you want to find slides for (I assume) any of the JavaOne sessions, you can search the content catalog.

However, for those interested in my sessions, the three talks I gave were the following:

  1. UI Controls and Charts: Drag-and-Drop, Filtering, Sorting, Table Hookup with Charts.
    Paru Somashekar and Jonathan Giles.
    Download slides.
  2. JavaFX Datasources: Getting Real-World Data into JavaFX Controls.
    Johan Vos and Jonathan Giles.
    Download slides. For more information, visit the DataFX website.
  3. Custom UI Controls and Charts with JavaFX 2.0.
    Jasper Potts and Jonathan Giles.
    Download slides.
FXML + Guice

FXML + Guice

There has been a very interesting thread in the JavaFX OTN forums about FXML and dependency injection. I went and downloaded Google Guice and wrote a small sample to try it all out. Things are not perfect quite yet (I still need full Unified Expression Language support added to FXML), but so very, very, very close!

What I ultimately hope to accomplish with FXML and CSS in JavaFX enterprise applications is that we (a) fully separate the visuals from the “controller”, (b) are left with a very simple “controller” that is highly testable, and (c) everything is highly modular.

CSS allows the designer to come in after the fact and modify the look of a UI without the developer’s help, and without a full build cycle. FXML allows a developer or designer to alter the structure of the view without a full build cycle. So (a) should be well in hand, especially if the controller itself can be injected rather than declared directly in the FXML file as it is today. (I’m OK with, even prefer, saying “I would like to have a FooController for this FXML file, if you please”, but what would really rock is if the FooController were an interface or abstract class rather than always being a concrete class, such that a DI framework like Guice could find the appropriate implementation and supply it).
(more…)