Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Qt Academy Launch in California!

    Solved Embedding one QML into another QML not working in Embedded Qt

    Mobile and Embedded
    embedded qt eglfs opengl es2.0
    3
    5
    1178
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      Saisyam last edited by

      For example, I created a Rectangle QML file and want to use it in main QML. No errors are thrown or even app didn't crashed but the embedded QML is not rendered. My platform is custom Linux with EGLFS plugin on Qt Embedded 5.4

      ? 1 Reply Last reply Reply Quote 0
      • ?
        A Former User @Saisyam last edited by

        @Saisyam Hi! Please show us your main.cpp and main.qml.

        1 Reply Last reply Reply Quote 0
        • Z
          Zakaria last edited by

          hi,
          you can use Loader

          Rectangle {
              id : r1;
              anchors.fill: parent;
              Loader {
                     id :  l1;
                     anchors.fill : parent;
                     source : "page2.qml";
               }
          }
          

          this works for me on windows android linux

          1 Reply Last reply Reply Quote 0
          • S
            Saisyam last edited by

            Thanks for the reply. Apologies for responding so late. I will try and get back to you.

            1 Reply Last reply Reply Quote 0
            • S
              Saisyam last edited by

              It is working fine. Thanks for the help

              1 Reply Last reply Reply Quote 0
              • First post
                Last post