Best practice to save and restore QML ApplicationWindow state and geometry

hope you can help me out. There is a best practice documentation for QWidget to save and restore window geometry and status: link. I tested that extensively and it works really great. I even detached a second monitor on Windows and it worked as expected.

What would be the best practice for QML ApplicationWindow. I could not find any top level class that would derive from QWidget and provide those functions.

@benlau Many thanks for the reply. I did play around with that and it does work for "normal" operation. The QWidget code covers all the "non-normal" cases, as well. I wanted to avoid to re-implement all that.