Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Inner component like property. How?
Forum Updated to NodeBB v4.3 + New Features

Inner component like property. How?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
2 Posts 1 Posters 160 Views
  • 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.
  • B Offline
    B Offline
    bogong
    wrote on last edited by
    #1

    Hello all!
    I need to create component in QML that will include sub-component that can be accessed via property. For example:

    CustomComponent {
    
    	id: oCustomComponent;
    
    	InnerComponent1 {
    
    		id: oInner1;
    	}
    
    	InnerComponent2 {
    
    		id: oInner2;
    	}
    }
    

    The question is how to add next level of sub-components to Inner1 or Inner2 through calling oCustomComponent? For example:

    CustomComponent {
    
    	somethingToInnerComponent1: Rectangle {
    		// this rectangle attached inside of oInner1
    	}
    	somethingToInnerComponent2: Rectangle {
    		// this rectangle attached inside of oInner2
    	}
    }
    
    1 Reply Last reply
    0
    • B Offline
      B Offline
      bogong
      wrote on last edited by
      #2

      Solution found. Issue closed.
      The example published here

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved