Important: Please read the Qt Code of Conduct -

Setting width for Components which get placed using anchors

  • Hi,

    I often find, that I am trying to make a QML component, e.g. one screen in my application, which is usually displayed using anchors in the main application window, usually via. anchors.fill: parent

    Often I want to use the design view in QtCreator, which needs me to specify a width and height. If the width and height will later be set via the anchors to the parent, what values should I use for width and height?

Log in to reply