0

Link to screenshots: https://i.stack.imgur.com/bU99P.jpg First image is when the window is expanded, second one is when the program runs. The others is of the FXML file and the scenebuilder program.

I have looked this up and tried the various layout options in the scenebuilder program itself but none of them works as I wanted. I want the image to stay centered, and if possible, the arrow buttons to also be centered.
Thanks

Anon Li
  • 561
  • 1
  • 6
  • 18
  • Possible duplicate of [How do I center an Image view in an anchor pane?](https://stackoverflow.com/questions/20014787/how-do-i-center-an-image-view-in-an-anchor-pane) – Mohamed Benmahdjoub Nov 22 '18 at 13:55

1 Answers1

0

I'm a fan of BorderPanes. If you wrap your arrows to the Center of the BorderPane they will stay centerd, even if you resize your Scene.

So if You want the arrows and the big Image Centered use a BorderPane and wrap the Image to the Center. Now you can wrap another BorderPane in parent BorderPane's Bottom and wrap your Arrows to center.

twobiers
  • 1,057
  • 1
  • 11
  • 27