How to Make a Frameless Qt Window

Posted on Posted in Qt Tutorials, Tutorials

Frame in a window is the part of window that is crated and managed by the OS. It contains usually contains all borders and title bar of the window. To remove the frame of any window using Qt you need to use the following piece of code:

setWindowFlags(Qt::Window | Qt::FramelessWindowHint);

Note that this will also cause the title bar of the window to be removed which means there will be no “close”, “minimize” and “maximize” buttons. So, you can use this same piece of code to remove all buttons from the title bar.


Leave a Reply

Your email address will not be published. Required fields are marked *