This video is going to show you how to store in an .ini file the width and height of a scene after is closed. When the scene is opened back again it will restore to the same with and height.
ini4j download link: https://sourceforge.net/projects/ini4j/