📜  JavaFX教程

📅  最后修改于: 2020-10-14 00:58:25             🧑  作者: Mango

JavaFX教程

JavaFX教程提供了JavaFX的基本和高级概念。我们的JavaFX教程专为初学者和专业人士设计。

JavaFX是一个Java库,用于开发桌面应用程序和富Internet应用程序(RIA)。 JavaFX中内置的应用程序可以在多个平台上运行,包括Web,移动和桌面。

我们的JavaFX教程涵盖了JavaFX库的所有主题,例如基础知识,2D形状,3D形状,效果,动画,文本,布局,UI控件,转换,图表,带有CSS的JavaFX,带有媒体的JavaFX等。

什么是JavaFX?

JavaFX是一个Java库,用于开发桌面应用程序和富Internet应用程序(RIA)。 JavaFX中内置的应用程序可以在多个平台上运行,包括Web,移动和桌面。

JavaFX旨在取代Java应用程序中的swing作为GUI框架。但是,它提供的功能比swing多。像Swing一样,JavaFX也提供了自己的组件,并且不依赖于操作系统。它轻巧且硬件加速。它支持各种操作系统,包括Windows,Linux和Mac OS。

JavaFX的历史

JavaFX由Chris Oliver开发。最初,该项目被命名为Form Follows Functions(F3)。旨在为GUI应用程序开发提供更丰富的功能。后来,Sun Micro-systems于2005年6月收购了F3项目JavaFX。

Sun Micro-systems于2007年W3大会上正式宣布它。 2008年10月,发布了JavaFX 1.0。 2009年,ORACLE公司收购了Sun Micro-Systems,并发布了JavaFX 1.2。 JavaFX的最新版本是JavaFX 1.8,该版本于2014年3月18日发布。

JavaFX的功能

Feature Description
Java Library It is a Java library which consists of many classes and interfaces that are written in Java.
FXML FXML is the XML based Declarative mark up language. The coding can be done in FXML to provide the more enhanced GUI to the user.
Scene Builder Scene Builder generates FXML mark-up which can be ported to an IDE.
Web view Web pages can be embedded with JavaFX applications. Web View uses WebKitHTML technology to embed web pages.
Built in UI controls JavaFX contains Built-in components which are not dependent on operating system. The UI component are just enough to develop a full featured application.
CSS like styling JavaFX code can be embedded with the CSS to improve the style of the application. We can enhance the view of our application with the simple knowledge of CSS.
Swing interoperability The JavaFX applications can be embedded with swing code using the Swing Node class. We can update the existing swing application with the powerful features of JavaFX.
Canvas API Canvas API provides the methods for drawing directly in an area of a JavaFX scene.
Rich Set of APIs JavaFX provides a rich set of API’s to develop GUI applications.
Integrated Graphics Library An integrated set of classes are provided to deal with 2D and 3D graphics.
Graphics Pipeline JavaFX graphics are based on Graphics rendered pipeline(prism). It offers smooth graphics which are hardware accelerated.
High Performance Media Engine The media pipeline supports the playback of web multimedia on a low latency. It is based on a Gstreamer Multimedia framework.
Self-contained application deployment model Self Contained application packages have all of the application resources and a private copy of Java and JavaFX Runtime.

JavaFX索引

先决条件

在学习JavaFX之前,您必须具有Java的核心知识。您还必须熟悉Eclipse或NetBeans。本教程中的所有示例均已在Eclipse IDE上进行了测试。

听众

我们的JavaFX教程旨在帮助初学者和专业人员。