习惯了Swing编程,听说过JavaFX。它是否应该取代 Swing 成为用 Java 编写桌面应用程序的首选平台?
换句话说,我应该为我的新项目选择 JavaFX 吗?
最佳答案
是的,JavaFX 正在取代 Swing。
另见Oracle官方文档:
http://www.oracle.com/technetwork/java/javafx/overview/faq-1446554.html#6
Is JavaFX replacing Swing as the new client UI library for Java SE?
Yes. However, Swing will remain part of the Java SE specification for the foreseeable future, and therefore included in the JRE. While we recommend developers to leverage JavaFX APIs as much as possible when building new applications, it is possible to extend a Swing application with JavaFX, allowing for a smoother transition.
另请参阅 SO 帖子:
关于java - JavaFX 应该取代 Swing 吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21368990/