How can I center the main window?

My MainWindow has a width of 1200.

When I show it, the left side is at 1/3th of the width of my screen, so the rightmost part falls outside the screen.
How can I center it on the screen?

Hello @opagust welcome to the forum!

Default window positioning is the responsibility of the window manager & is platform dependent. What platform are you using?

Thanks for the quick reply, Martin

I’m using Windows 11.

Can I find the anwer in your book?

I found the answer here : pyside6 Center Window