Rather than have a giant sidebar that’s difficult to read, I thought I’d create this welcome post and sticky it to the top of the page. This isn’t expected to be static, and I welcome any suggestions for changes and additions, just add a comment to this post.

What is JavaFX?

JavaFX is a software platform and a graphical user interface (GUI) toolkit that allows developers to create rich and interactive applications for desktop, mobile, and embedded devices. It provides a powerful set of tools and APIs for building modern, visually appealing applications.

The platform that we now know as JavaFX was introduced as a successor to the Swing framework around the time that Java 1.8 was released. It is designed to provide a more advanced and flexible way of developing user interfaces compared to Swing, with improved graphics and multimedia capabilities.

How is JavaFX Different from Swing?

Swing is much older than JavaFX and this age is reflected in the approach that is taken with it. The following list summarizes the key differences between the two toolkits:

  1. Styling and CSS: JavaFX supports cascading style sheets (CSS), enabling developers to separate the visual appearance of the application from its logic. CSS can be used to define colors, fonts, layout, and other visual properties, making it easier to customize and maintain the application’s look and feel.
  2. Multimedia Support: JavaFX includes native support for multimedia elements, such as audio, video, and 2D/3D graphics. It provides APIs for playing media files, rendering images, and creating animated visual effects.
  3. Properties and Bindings: JavaFX includes an extensive library of Observable classes that make it extremely easy to create relationships between the GUI and a Presentation Model. This allows JavaFX to easily support “Reactive” application designs.
  4. Extensive Animation Support: JavaFX has native support for animations and gradual transitions. Virtually any property of a Node can be associated with an animation.
  5. Modern Look and Feel: “Out of the box”, JavaFX applications look much more modern than Swing applications. It is possible to update the look and feel of Swing, but requires extensive programming.

Useful Links

“Official Links”

  1. OpenJFX.io This is the “home” of JavaFX, and a good place to get started to download the SDK and see some documentation.
  2. API Documentation This link is for version 20.
  3. JavaFX CSS Reference Guide Indispensible information when you’re designing your style sheets.
  4. The Modena Stylesheet This is a slightly earlier version, but you can pull it out of your SDK if you need a newer one. This is essential if you want to understand how to style the standard JavaFX Nodes.
  5. The Source Code The GitHub project with the source code.
  6. [OpenJDK Wiki] (https://github.com/openjdk/jfx/)
  7. Scene Builder The “drag and drop” screen designer tool.

Other Communities/Aggregators

  1. JFX-Central
  2. Foojay.io Posts links to new JavaFX content on the web on a regular basis.
  3. AwesomeJavaFX Has links to virtually every site with cool JavaFX content.
  4. r/javafx

Blogs

I was going to put in a list of blogs with active JavaFX content, but all the ones I could find have gone quite a while without any new content. If you find any, let me know.

Useful Projects and Libraries

  1. ControlsFX Pretty much the standard library of extra controls for JavaFX.
  2. AtlantaFX Modern styling for JavaFX using SASS.
  3. DirtyFX Implementation of Properties that tracks changes from a base value.
  • @UFODivebomb
    link
    111 months ago

    Thanks! The OpenJDK wiki link is broken on Jerboa.