May 2019
Intermediate to advanced
542 pages
13h 37m
English
When a QWidget is created without a parent and its show() method is called, it becomes a top-level window. When we use it as a top-level window, such as we do with our MainWindow instance, there are some window-specific properties we can set. Some of these are shown in the following table:
| Property | Argument type | Description |
|---|---|---|
| windowTitle | string | The title of the window. |
| windowIcon | QIcon | The icon for the window. |
| modal | Boolean | Whether the window is modal. |
| cursor | Qt.CursorShape | The cursor used when this widget has hovered. |
| windowFlags | Qt.WindowFlags | How the OS should treat the window (dialog, tooltip, popup). |
The argument type for cursor is an example of an enum. An enum is simply a list of named ...
Read now
Unlock full access