It is quite simple because you are using the FXMLBuilder.
Just follow these simple steps:
- Open FXML file into FXMLBuilder.
- Select the stack pane.
- Open the Layout tab [left side tab of FXMLBuilder].
- Set the sides value by which you want to compute the pane size during stage resize like TOP, LEFT, RIGHT, BOTTOM.