VBox vbox = new VBox();
vbox.setStyle("-fx-background-color:#757575; -fx-text-fill:#eaeaea");
vbox.setPadding(new Insets(10));
vbox.setSpacing(7);
RadioButton rbUseTextArea = new RadioButton("Text Area");
rbUseTextArea.setToggleGroup(OGroup);
RadioButton rbUseFileSource = new RadioButton("File (drag and drop)");
rbUseFileSource.setSelected(true);
rbUseFileSource.setToggleGroup(OGroup);
addBlueTitle(vbox, "Transform Settings");
vbox.getChildren().add(new Separator());
addTitle(vbox, "Source");
vbox.getChildren().add(rbUseTextArea);
vbox.getChildren().add(rbUseFileSource);
vbox.getChildren().add(new Separator());
rbUseTextArea.setOnMouseClicked(new EventHandler<MouseEvent>() {
@Override
public void handle(MouseEvent e) {
row2.setMinHeight(60);
row2.setMaxHeight(250);
textVBox.setMaxHeight(USE_COMPUTED_SIZE);
//textVBox.setStyle("-fx-background-color:blue;");
row2.setPrefHeight(USE_COMPUTED_SIZE);
locationField.setEditable(false);
locationField.setStyle("-fx-background-color:#757575; -fx-text-fill:#f1f1f1; border-width:1");
textArea.prefHeightProperty().bind(textVBox.prefHeightProperty());
useTextArea = true;
}
});
rbUseFileSource.setOnMouseClicked(new EventHandler<MouseEvent>() {
@Override
public void handle(MouseEvent e) {
textVBox.setMaxHeight(0);
row2.setMinHeight(0);
row2.setMaxHeight(0);
locationField.setEditable(true);
locationField.setStyle("-fx-background-color:#454545; -fx-text-fill:#f1f1f1; border-width:1");
useTextArea = false;
}
});
addTitle(vbox, "Font");
RadioButton rb1 = new RadioButton("Monospaced");
rb1.setUserData("");
rb1.setToggleGroup(fontGroup);
RadioButton rb2 = new RadioButton("Source Code Pro");
rb2.setUserData("scp");
rb2.setSelected(true);
rb2.setToggleGroup(fontGroup);
vbox.getChildren().add(rb1);
vbox.getChildren().add(rb2);
vbox.getChildren().add(new Separator());
addTitle(vbox, "Color Theme");
RadioButton crb1 = new RadioButton("Solarized-Dark");
crb1.setUserData("dark");
crb1.setToggleGroup(colorGroup);
crb1.setSelected(true);
RadioButton crb2 = new RadioButton("Solarized-Light");
crb2.setUserData("light");
crb2.setToggleGroup(colorGroup);
RadioButton crb5 = new RadioButton("GitHub (Light)");
crb5.setUserData("github");
crb5.setToggleGroup(colorGroup);
RadioButton crb6 = new RadioButton("GitHub (Blue)");
crb6.setUserData("github-blue");
crb6.setToggleGroup(colorGroup);
RadioButton crb3 = new RadioButton("RoboTicket");
crb3.setUserData("roboticket-grey");
crb3.setToggleGroup(colorGroup);
RadioButton crb4 = new RadioButton("Tomorrow-Night");
crb4.setUserData("tomorrow-night");
crb4.setToggleGroup(colorGroup);
RadioButton crb7 = new RadioButton("PG-Light");
crb7.setUserData("pg-light");
crb7.setToggleGroup(colorGroup);
crb1.setStyle("-fx-background-color:#757575; -fx-text-fill:#eaeaea;");
vbox.getChildren().add(crb1);
vbox.getChildren().add(crb2);
vbox.getChildren().add(crb5);
vbox.getChildren().add(crb6);
vbox.getChildren().add(crb7);
vbox.getChildren().add(crb3);
vbox.getChildren().add(crb4);
vbox.getChildren().add(new Separator());
// for (Node n : vbox.getChildren()){
// n.setStyle("-fx-background-color:#757575; -fx-text-fill:#eaeaea;");
// }
//
addTitle(vbox, "Language");
RadioButton drb1 = new RadioButton("Auto");
drb1.setUserData("");
drb1.setToggleGroup(docGroup);
drb1.setSelected(true);
RadioButton drb2 = new RadioButton("XSLT");
drb2.setUserData("xslt");
drb2.setToggleGroup(docGroup);
RadioButton drb3 = new RadioButton("XQuery/XPath");
drb3.setUserData("xquery");
drb3.setToggleGroup(docGroup);
RadioButton drb4 = new RadioButton("XML Schema");
drb4.setUserData("xsd");
drb4.setToggleGroup(docGroup);
RadioButton drb5 = new RadioButton("XProc");
drb5.setUserData("xproc");
drb5.setToggleGroup(docGroup);
RadioButton drb6 = new RadioButton("Schematron");
drb6.setUserData("schematron");
drb6.setToggleGroup(docGroup);
RadioButton drb7 = new RadioButton("DeltaXML");
drb7.setUserData("deltaxml");
drb7.setToggleGroup(docGroup);
vbox.getChildren().add(drb1);
vbox.getChildren().add(drb2);
vbox.getChildren().add(drb3);
vbox.getChildren().add(drb4);
vbox.getChildren().add(drb5);
vbox.getChildren().add(drb6);
vbox.getChildren().add(drb7);
vbox.getChildren().add(new Separator());
addTitle(vbox, "XSLT Project");
RadioButton tocrb1 = new RadioButton("Yes");
tocrb1.setUserData("yes");
tocrb1.setToggleGroup(tocGroup);
RadioButton tocrb2 = new RadioButton("No");
tocrb2.setUserData("no");
tocrb2.setToggleGroup(tocGroup);
tocrb2.setSelected(true);
vbox.getChildren().add(tocrb1);
vbox.getChildren().add(tocrb2);
for (Node n : vbox.getChildren()){
n.setStyle("-fx-background-color:#757575; -fx-text-fill:#eaeaea;");