Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.15
-
None
Description
https://stackoverflow.com/questions/31426528/saving-window-state-with-qml explains it, so I'll just quote part of that here:
The documentation gives the following method:
Settings { property alias x: mainWindow.x property alias y: mainWindow.y property alias width: mainWindow.width property alias height: mainWindow.heightHowever that has three flaws:
1. It writes to the settings file continuously when you resize / move the window.
2. It doesn't remember whether the window is maximised or not (Notepad++ also suffers from this annoying flaw btw).
3. If you maximise the window it doesn't save the unmaximised geometry.
We should make this work out of the box, or provide a convenience type if that's not possible. It shouldn't be necessary to resort to such lengthy workarounds just to save a window's state.