I wanted to know if it is possible to call a JavaFX screen through a Swing Screen Button. The code for the JavaFX screen I want to call is the following:
public class EditorHTML extends Application {
public static void main(String[] args) {
Application.launch(args);
}
@Override
public void start(Stage stage) {
// Crie o HTMLEditor
HTMLEditor htmlEditor = new HTMLEditor();
// Definir a altura do HTMLEditor
htmlEditor.setPrefHeight(300);
// Definir a largura do HTMLEditor
htmlEditor.setPrefWidth(600);
// Crie a cena
Scene scene = new Scene(htmlEditor);
// Adicione a cena ao palco
stage.setScene(scene);
// Definir o título do palco
stage.setTitle("HTMLEditor Exemplo");
stage.show();
}
}