I'm working on wizard installer in JavaFX and I need few windows with AnchorPnane with this same size. Now in *.fxml file I have lines:
<AnchorPane prefHeight="300.0" prefWidth="300.0"
I will have few similar files *.fxml so I need keep information about size in my java class:
public final int HeightOfAnchorPane=300;
public final int WidthOfAnchorPane=300;
How can I set value of height and width to file *.fxml from my java class? Like this:
<AnchorPane prefHeight = HeightOfAnchorPane prefWidth= WidthOfAnchorPane
EDIT: @james-d I thank you for this post: How can I make constant variables in Javafx for XML files but if I import class in *.fxml file I couldn't open file with SceneBuilder. Someone can fix it?