iconSwitchText.setOnSelect(switchEvent -> System.out.println("Icon Switch Text switched on"));
iconSwitchSymbol1.setOnSelect(switchEvent -> System.out.println("Icon Switch Symbol 1 switched on"));
}
@Override public void start(Stage stage) {
VBox pane = new VBox();
pane.setPadding(new Insets(10, 10, 10, 10));
pane.setBackground(new Background(new BackgroundFill(Color.web("#34495e"), CornerRadii.EMPTY, Insets.EMPTY)));
pane.setSpacing(20);
pane.setAlignment(Pos.CENTER);
pane.getChildren().addAll(onOffSwitch, iconSwitchSymbol, iconSwitchText, iconSwitchSymbol1);
Scene scene = new Scene(pane, 100, 150);
stage.setTitle("OnOffSwitch");
stage.setScene(scene);