Qt Forum

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

    Pass a Component into pushed StackView items

    QML and Qt Quick
    stackview component
    1
    1
    474
    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
      sk2212 last edited by

      Within a StackView I want to pass an Item (In this case a TabView Component) to pushed StackView Components.

      So, the main question => How to pass a visual item into a QML component and be able to CHANGE this component within all QML components where it is used?

      Something like this is working for non-pushed StackView items:

      Item {
      width: 100
      height: 100
      property var passedComponent
      Item {
      children: passedComponent
      }
      }

      However, changing the "passedComponent" is only changed within same QML Component. Why? Is is not passed via "reference?

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