Index: .classpath
===================================================================
--- .classpath	(revision 15888)
+++ .classpath	(working copy)
@@ -82,6 +82,9 @@
 			<accessrule kind="discouraged" pattern="javafx/scene/media/**"/>
 			<accessrule kind="discouraged" pattern="com/sun/javafx/application/PlatformImpl"/>
 			<accessrule kind="discouraged" pattern="javafx/util/Duration"/>
+			<accessrule kind="discouraged" pattern="javafx/scene/**"/>
+			<accessrule kind="discouraged" pattern="javafx/embed/swing/JFXPanel"/>
+			<accessrule kind="discouraged" pattern="javafx/application/Platform"/>
 		</accessrules>
 	</classpathentry>
 	<classpathentry kind="lib" path="tools/pmd/commons-lang3-3.8.1.jar">
Index: src/org/openstreetmap/josm/gui/JavaFXWrapper.java
===================================================================
--- src/org/openstreetmap/josm/gui/JavaFXWrapper.java	(nonexistent)
+++ src/org/openstreetmap/josm/gui/JavaFXWrapper.java	(working copy)
@@ -0,0 +1,51 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.gui;
+
+import javafx.application.Platform;
+import javafx.embed.swing.JFXPanel;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+
+/**
+ * This wrapper class wraps arbitrary JavaFX Nodes, so that they can easily be
+ * added to a Swing UI.
+ *
+ * @author Taylor Smock
+ * @param <T> Some class that extends {@link Node}
+ * @since xxx
+ */
+public class JavaFXWrapper<T extends Node> extends JFXPanel {
+    T node;
+
+    /**
+     * @param node The JavaFX node that will be returned later with
+     *             {@link JavaFXWrapper#getNode}.
+     */
+    public JavaFXWrapper(T node) {
+        super();
+        this.node = node;
+        Platform.runLater(() -> initFX());
+    }
+
+    private void initFX() {
+        Scene scene = createScene();
+        setScene(scene);
+    }
+
+    private Scene createScene() {
+        Group group = new Group();
+        Scene scene = new Scene(group);
+        group.getChildren().add(node);
+        return scene;
+    }
+
+    /**
+     * Get the JavaFX {@link Node}
+     *
+     * @return The Node passed to the class during construction
+     */
+    public T getNode() {
+        return node;
+    }
+}
