It also includes Charts, which the user can also interact with, as well as the code for skinning all of these parts with css. That’s generally anything the user can change, like buttons, boxes and fields. This set of classes defines all the UI controls. It defines the SwingNode to allow you to include Swing components in JavaFX, and the JFXPanel, to include JavaFX nodes in Swing apps. If you need Swing/JavaFX interoperability, this is the dependency you’ll need. It also has more general classes for animation, css, geometry and windowing. It contains the classes for rendering, image handling, transition and transformation effects. This Defines the core scenegraph APIs for the JavaFX UI toolkit. BaseĬontains the simplest JavaFX constituent classes, such as Bindings, Properties, Collections, Events and some basic Util classes. We’ll quickly go through each in turn, and then look at the dependencies that exist between JavaFX modules. It’s the common JavaFX classes that every JavaFX program will need. For example, every module requires javafx.base. Not only do they each have different functions, but they also have dependencies between each other. It’s 4 clicks to add Maven and then a few lines of XML code to set up your project at the right language level. IntelliJ makes adding Maven to a project incredibly simple. All JavaFX styles are prefixed with “-fx-” to allow standard and JavaFX styles to be stored in the same file. JavaFX UI elements are all skinnable by CSS. Can also be used to add custom elements, although this is a little less clean. Unlike in HTML, in JavaFX it does have default stylingĬontrols the environment, adding functionality to the elements defined in the FXML file. Here’s each part with quick description of what each file does: File The Controller…well…that’s the controller part…Īs the developer, you’re responsible for developing the models (the data structures) that fill the UI with information. It’s based on the Model-View-Controller paradigm, with the FXML file fulfilling the View part. The JavaFX application itself mimics to a certain extent the HTML/JavaScript/CSS web framework. There are only two steps to asking IntelliJ to give you a JavaFX project: OK, let’s dive in! We’ll go through the 4 steps one by one. And, when you come to debugging, you’ll know what to do! So by the end, you’ll understand what dependency management you’ve added. But the hints and tips really help later down the line when something goes wrong and you need to debug. If you just need to get the project done, skip through and come back later. We’ve scattered optional hints and tips throughout the article.