setWindowFlags()
There are also a number of flags which you can use to customize the appearance of top-level windows. These have no effect on other windows:
只能影响置顶显示的窗口,对其它窗口不会有影响
Constant | Value | Description |
Qt::MSWindowsFixedSizeDialogHint | 0x00000100 | Gives the window a thin dialog border on Windows. This style is traditionally used for fixed-size dialogs. |
Qt::MSWindowsOwnDC | 0x00000200 | Gives the window its own display context on Windows. |
Qt::BypassWindowManagerHint | 0x00000400 | This flag can be used to indicate to the platform plugin that "all" window manager protocols should be disabled. This flag will behave different depending on what operating system the application is running on and what window manager is running. The flag can be used to get a native window with no configuration set. |
Qt::X11BypassWindowManagerHint | BypassWindowManagerHint | Bypass the window manager completely. This results in a borderless window that is not managed at all (i.e., no keyboard input unless you call QWidget::activateWindow() manually). |
Qt::FramelessWindowHint | 0x00000800 | Produces a borderless window. The user cannot move or resize a borderless window via the window system. On X11, the result of the flag is dependent on the window manager and its ability to understand Motif and/or NETWM hints. Most existing modern window managers can handle this. |
Qt::NoDropShadowWindowHint | 0x40000000 | Disables window drop shadow on supporting platforms. |