JavaFX helps build Java application interface

But what does JavaFX offer more than XAML or HTML 5 or Swing? Who is most interested in this new Java publisher solution?

The figure below shows an example of an interface implemented with JavaFX and it looks amazing!


MP3 player - a demonstration of the interface performed using JavaFX.
It is featured on the JavaFX site with its source code.

It actually appeals to designers and programmers alike...
Java wants to go beyond the desktop and install on browsers, as well as on mobile and any multimedia device.
This is the purpose of the RIA platform, which can be used directly or indirectly:

So webmasters are concerned about this framework in all UI-related features.

In 2018, Oracle decided to make JavaFX a separate tool from Java, as well as distribute it on the OpenJFX website. At the same time, it is increasing its investment in AWT/Swing, which indicates its disinterest in JavaFX.

Framework for office, Internet or mobile devices

JavaFX wants to be a framework for web applications as well as mobile applications. This competes with several already popular frameworks, as well as Android, Google's development platform and mobile OS.

It simplifies the creation of interfaces than Swing, but not all components of the latter had an equivalent in JavaFX. Over time, it ceases to be.

JavaFX focuses on audio and video capabilities, bound text and vector graphics, animations and web services. It provides examples that will work on your computer with the latest version of Java.

Current versions of Java for PC and mobile devices show incompatibility. JavaFX wants to remove them and offer a single framework for all online applications.
Thus, mobile applications will be able to work on a PC. Similarly, for web applications, you can move an application running on a web page on the desktop by simply dragging and dropping.

The platform consists of several parts:

To start developing your application, download the SDK, and then read the launch guide. (English).

For ease of development, a new programming language, JavaFX Script was introduced as allowing you to write in 25 lines what is written in 100 lines of Java, but it no longer works with version 2.0 of JavaFX and therefore should be forgotten!

Own installation

Starting with version 2.2, you can install an application built with JavaFX as a binary application, without depending on the preliminary setting of the Java runtime on the machine.
The application is packaged in its own runtime, a personal copy of the Java classes needed to run it, as well as images and other resources needed for the interface. This is at the expense of disk space, but at the expense of eliminating any compatibility issues.

Thus, a GCJ compiler is no longer needed to create an executable file. This system was actually suitable primarily at a time when computers were less fast, and when there were much fewer classes in runtime. Their gradual increase discouraged the developers of these binary Java compilers.
Current computers may be happy with the JIT interpreter, and this package simplifies installation.

One of the reasons for the appearance - a little belated - of this system - after it lost a lawsuit against Google, Oracle sees this as a way to install classic Java applications (not Dalvik) on mobile Android .

Conclusion

The examples on the site are impressive. This new infrastructure begins with strengths: application versatility, a free NetBeans development tool that greatly simplifies software implementation. JavaFX further complicates the choice of developers, who will now fluctuate between at least three platforms: HTML 5, XAML, JavaFX!

See GUI List to select from all GUI solutions.