Window manager now automatically stores/loads window position

At present, the old main form window location code (and preferences file
data) is still intact, because we use that to determine which monitor
displays the splash screen.  I will rework that in time.

As for this commit, it automatically saves/loads the last-known location
of both the main form and toolbox windows.  Image window data is not
stored, although we theoretically could store/load it without any extra
work, which could be used to make a nice "resume last session"
feature... I've made a note of this.

Also included are various improvements to the window manager as a whole,
such as properly moving tool windows when the main form is resized.