Installing JavaFX Scene Builder
This guide provides information on how to download and install JavaFX Scene Builder 1.1 on a Windows, Linux, or Mac OS X system. Download information for the JavaFX Scene Builder samples is also included.
JavaFX Scene Builder is a design tool that enables you to drag and drop graphical user interface (GUI) components onto a JavaFX scene. It can help you to quickly prototype interactive applications that connect GUI components to the application logic. It automatically generates the FXML source code as you define the GUI layout for your application.
Use the following information to prepare your system for installing Scene Builder.
Ensure that your system meets the system requirements listed in the
current JavaFX System Requirements document listed on the JavaFX 2 Release Documentation page. JavaFX Scene Builder 1.1 release supports the same platforms that are listed in
JavaFX Certified System Configurations, including Linux and Mac OS X 10.8.
To successfully complete the
JavaFX Scene Builder Getting Started tutorial, it is highly recommended that you also install the following software. However, there are also instructions in the
JavaFX Scene Builder Getting Started tutorial that guide you to complete the sample application using only a standalone JavaFX Scene Builder tool and the ANT utility. You can also use the
Using JavaFX Scene Builder with Java IDEs to get information about how to use other Java IDEs to create JavaFX projects and use Scene Builder to work on the FXML file for your application's GUI.
Latest NetBeans IDE 7.4 software to utilize the tight integration with JavaFX Scene Builder that allows you to easily create a new FXML file, edit it using JavaFX Scene Builder, modify and compile your Java controller source files, and run the sample application used in the tutorial. Download the NetBeans IDE 7.4 software from
http://netbeans.org/downloads/. For information about configuring NetBeans IDE to run with a specific JavaFX version, see Setting Up NetBeans IDE with JavaFX at
The JavaFX Scene Builder is available as a Windows package (.msi) for the Windows platform, as a Debian package (.deb) or .tar.gz file for the Linux platform, and as a disk image (.dmg) for the Mac OS X platform.
Download JavaFX Scene Builder Download from the JavaFX General Availability download page at
In the JavaFX Scene Builder 1.1 section, accept the license agreement, if you agree to its terms.
Click the link for your operating system and follow the prompts to save the installer file.
Use the following information to install in your specific platform.
(Windows platform) Run the
javafx_scenebuilder-1_1-windows.msi installer file. Respond to the prompts as indicated in the installation wizard.
By default, the JavaFX Scene Builder software is installed at
C:\Program Files\Oracle\JavaFX Scene Builder 1.1 on a Windows platform. If you install JavaFX Scene Builder on a 64-bit Windows machine, the default installation location is C:\Program Files (x86)\Oracle\JavaFX Scene Builder 1.1.
(Linux platform) Extract the Scene Builder 1.1 files from the
.tar.gzto a directory on your local file system, or double-click the
.debfile to open it with Ubuntu Software Center, where <platform> is either x64 or i586.
(Mac OS X platform) Open the
file and drag the
JavaFX Scene Builder 1.1.appapplication into the Applications folder.
For any of the supported platforms, the installed software contains the files similar to or a subset of what is shown in Figure 1, which shows the installation layout on a Windows platform.
Figure 1 Contents of a JavaFX Scene Builder 1.1 Installation on a Windows Platform
Description of "Figure 1 Contents of a JavaFX Scene Builder 1.1 Installation on a Windows Platform"
/app - Contains the JavaFX Scene Builder properties files and libraries.
/runtime - Contains a copy of the Java Runtime Environment (JRE), which includes executable files and libraries that enable JavaFX Scene Builder to run standalone.
COPYRIGHT.html - Contains the copyright information for JavaFX Scene Builder.
JavaFX Scene Builder 1.1.exe - JavaFX Scene Builder executable file.
JavaFX Scene Builder 1.1.ico - JavaFX Scene Builder icon file.
msvcr100.dll - Microsoft runtime library.
README.html - Contains a pointer to the JavaFX Scene Builder README page.
THIRDPARTYLICENSEREADME.txt - Contains the list of third-party licenses.
To get started with Scene Builder, read through the following documentation that can be found at
JavaFX Scene Builder Overview- A high level overview of the JavaFX Scene Builder 1.1 tool
JavaFX Scene Builder User Guide- An introduction to the user interface and features of JavaFX Scene Builder 1.1
Getting Started with JavaFX Scene Builder- A step-by-step tutorial for creating the FXML file that defines the user interface of a simple issue tracking application
Using JavaFX Scene Builder with Java IDEs- A tutorial that gives information about how to configure the NetBeans, Eclipse, or IntelliJ IDEs to use with Scene Builder
You can also view the
Getting Started with JavaFX Scene Builder 1.0 video tutorial, which shows the steps to create the same FXML file for the simple issue tracking application sample.
Running the JavaFX Scene Builder Samples
Download the JavaFX Scene Builder samples to see some applications you can build using the Scene Builder tool.
Go to the JavaFX Scene Builder Samples section of the download page at
Locate the JavaFX Scene Builder section, click the Samples link, and follow the prompts to save the
javafx_scenebuilder_samples-1_1.zipfile to your local file system.
Extract the sample files from the zip file to a directory on your local file system.
Each sample is a NetBeans project and also includes at least one JavaFX layout stored as an FXML file. The <sample>.fxml file can be loaded and edited using the JavaFX Scene Builder.
To run the samples, you must have the JDK 7 software with JavaFX 2.2 support or JDK 6 plus JavaFX 2.2 installed on your system. Since the samples include the corresponding NetBeans projects files, using the NetBeans IDE is the simplest way to run the sample applications. However, you can also run them using the Ant utility, Eclipse, or IntelliJ IDEA. See below for more information.
Using NetBeans IDE
Use NetBeans 7.4 or later to run the JavaFX Scene Builder samples.
Go to the javafx_scenebuilder_samples-1_1-install directory in which you extracted the sample files.
Run a sample by opening the project in the NetBeans IDE, compiling it, and then running it. For example, to run the HelloWorld application, open the HelloWorld project in NetBeans IDE, right-click the project node in the Projects window, and select Run.
Source code for each sample is in the src folder for each NetBeans project.
If you encounter an error running the sample, check that the JavaFX Platform settings in NetBeans IDE are configured correctly. For information about configuring NetBeans IDE to run with a specific JavaFX version, see Setting Up NetBeans IDE With JavaFX at
Using Eclipse or IntelliJ IDEA
Using JavaFX Scene Builder with Java IDEs for information on how to run the samples in either the Eclipse or IntelliJ IDEA environment.
Using the Ant Utility
If you choose not to run the samples in NetBeans or any other IDE, you can use the Apache Ant utility (version 1.8 or later) to build and run the sample application on the command line. Enter a command similar to that in Example 1. Note that the examples shown use JDK 7.
Example 1 Ant Command to Run the Sample Application
ant -Dplatforms.Default_JavaFX_Platform.home=<JAVA_HOME> -f <JavaFX_Sample_App_Name>/build.xml <TARGET>
The main values for <TARGET> are clean, jar, and run. You can set <TARGET> with the value of -projecthelp to get a list of available targets. For example, to run the HelloWorld application on the Windows platform, type something similar to that in Example 2.
Example 2 Using Ant to Run the HelloWorld Sample on a Windows Platform
ant -Dplatforms.Default_JavaFX_Platform.home="C:\Program Files\Java\jdk1.7.0_x" \ -f HelloWorld/build.xml run
To run the HelloWorld application on a Mac OS X platform with Java SE 7 update 40 software installed, type the command shown in Example 3.