I know that this is done using flags, but I do not understand the correct syntax in qml:

Window { ... flags: "Qt::CustomizeWindowHint", "Qt::WindowCloseButtonHint"... ... } 

At the moment, this option does not give the desired result (only the first flag is accepted). Options with flags in some quotes also did not pass.

The MSWindowsFixedSizeDialogHint flag MSWindowsFixedSizeDialogHint not MSWindowsFixedSizeDialogHint , since it blocks window movements (should it do that?)

Help with an example of how to set the flags correctly and fix the window size.

    1 answer 1

    Maybe there is some kind of “wise” method that I do not know, but your problem can be solved like this:

     Window { visible: true width: 360 height: 360 maximumHeight: height maximumWidth: width minimumHeight: height minimumWidth: width } 

    To remove the minimize and maximize buttons, you can use the following combination of flags:

     flags: Qt.Window | Qt.CustomizeWindowHint | Qt.WindowTitleHint | Qt.WindowCloseButtonHint | Qt.WindowSystemMenuHint 
    • Sorry, I can’t try right now - does the button expand it hide the “expand” item in the menu? - Mira
    • @Mira, no, the buttons remain, but the window size does not change. Buttons should not be? - ixSci
    • Tomorrow I’ll find out if I can leave the button) @ixSci thanks a lot, really helping me out :) - Mira
    • @Mira, added a combination of flags to remove buttons. - ixSci 4:05 pm
    • one
      @Mira, JavaScript works in QML, so if anything, you need to look at the JavaScript documentation - ixSci