Install JavaFX and Scene Builder
The official installation instructions π are quite complete, but it may be useful to add additional approaches if they don't work for you.
IntelliJ IDEA 2023 - JavaFX
- Navigate to
Project Structure > Libraries
- Click on
+
>From Maven
- Enter
org.openjfx:javafx-fxml:18
for version18
- Do not check
sources
andjavadoc
unless you plan to manually handle them as they can't be in the same folder as the.jar
files (edit the library file in.idea
, and use a separate path).
- Enter
- π Navigate to
Edit Configurations
- press
ALT-V
to show the VM options input field - write inside
--module-path lib --add-modules javafx.controls,javafx.fxml
- press
IntelliJ IDEA 2020 - JavaFX
- Navigate to
Project Structure > Libraries
- Click on
+
>From Maven
- Enter
org.openjfx:javafx-fxml:16
for version16
- Enable the "Download to" option leading to the
lib
folder
- Enter
- π Navigate to
Edit Configurations
- press
ALT-V
to show the VM options input field - write inside
--module-path lib --add-modules javafx.controls,javafx.fxml
- press
IntelliJ IDEA - Scene Builder
- Navigate to
Settings > Languages & Frameworks > JavaFX
- Select the PATH leading to the installed Scene Builder
- π Use
new > FXML file
to create an FXML file - π Right-click on an FXML and select
Open in SceneBuilder
to...
Visual Studio - JavaFX
β‘οΈ Refer to this video.
- Install the JavaFX plugin
- Navigate to view
View > command palette
and create a project - Download JavaFX jars and put them in
lib
- π Navigate to
Run > add configuration > Java
- Append to the generated file:
"vmArgs": "--module-path lib --add-modules javafx.controls,javafx.fxml",
- Append to the generated file: