Qt World Summit: Register Today!

How to load leveled qml file into main qml?

  • Hi, maybe my question is bit awkward. But I need to load leveled qml into main.qml as shown below picture. But its not loading. Any help please?

    • Main.qml
    • MainPageBG.qml
    • mainui Folder
      • HeaderWidget.qml
      • MapWidget.qml


    Folder View:

  • Moderators

    did i understand you correctly that you want to show the MapWidget component as overlay on top of all the other elements?
    Since you are using ApplicationWindow already you can use the attached properties ApplicationWindow.contentItem or Overlay.overlay as the parent of the item

    Also note that in your code the Loader item is stacked behind MainPageBG element

  • @raven-worx thanks. my loader item is not stacked behind any other element. And its working.

Log in to reply