JavaFX version 21 has been released. We’ve tailored down some of the most exciting parts of the release in this document.
On Mac platforms, JavaFX 21 requires macOS 11 or later. An exception will be thrown when initializing the JavaFX runtime on older versions of macOS.
On Linux platforms, JavaFX 21 requires GTK3 version 3.8 or later. An exception will be thrown when initializing the JavaFX runtime if the GTK 3 library cannot be loaded.
removeEvent* have been added to
GridPane(double hgap, double vgap)
canStartNestedEventLoop which can used to check whether it is safe to start a nested event loop
underlineShape(int, int) to enable spellchecker decoration (squiggly line) under text region
showColumnMenu(mouseEvent), allowing developers to customize the behaviour when the table menu button is clicked
The community came together to fix 63 bugs in the last 6 months. Following are major bug-fixes that went into JavaFX 21:
Match.getPseudoClasses used to return an instance
PseudoClassState, which is a private class
NPE for drag and drop events
Finally, these are some dependency upgrades in JavaFX 20:
A more comprehensive list of all the changes in JavaFX 21 can be found on Github.