Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to wrap a swing component in a javaFX 2.0 application

The ability to wrap a swing component in a javaFX application seems to have vanished from javaFX 2:

javafx.ext.swing.SwingComponent

is not there any more in javaFX 2 beta API.

Is there still a way to do this in the new API?

like image 703
jumar Avatar asked May 27 '11 20:05

jumar


2 Answers

SwingNode class is used to embed a Swing content into a JavaFX application. Here is the link.

like image 83
rns Avatar answered Nov 15 '22 16:11

rns


There is 3rd-party support library, see http://rkennke.wordpress.com/2011/11/16/swing-in-javafx-demo/

like image 33
Sergey Grinev Avatar answered Nov 15 '22 17:11

Sergey Grinev