[Cuis-dev] saving and restoring window locations and sizes

Mark Volkmann r.mark.volkmann at gmail.com
Tue Dec 10 18:36:47 PST 2024


I experience two issues with window locations, probably because I work on a
super wide monitor (49") and use all of it for the Cuis window.

1) Sometimes (rarely) when I save the image, windows will move to new
locations.
2) Always when I open an image, the initial window is smaller than it was
when I saved the image and the windows do not reappear in their last
locations. I have to manually move them to where I like them.

I created a way to fix this that you might find interesting ... or you
might tell me there's a better way. See
https://github.com/mvolkmann/Cuis-Smalltalk-WindowManager. It provides a
method for saving window locations and sizes to a text file, and another
method that restores window locations and sizes from that file.

I position and size the windows how I like them and evaluate `SystemWindow
saveWindows`.
After quitting the image and later restarting it, I evaluate `SystemWindow
restoreWindows` and all the windows go to their saved locations and sizes.

-- 
R. Mark Volkmann
Object Computing, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20241210/9f9714f4/attachment.htm>


More information about the Cuis-dev mailing list