Button exitButton = new Button("Kilépés"); exitButton.setOnAction(event -> { System.exit(0); });