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. QML with C++ backend - dynamic components
Forum Updated to NodeBB v4.3 + New Features

QML with C++ backend - dynamic components

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 332 Views 1 Watching
  • 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.
  • benberliB Offline
    benberliB Offline
    benberli
    wrote on last edited by
    #1

    I am quite new to QML and am trying to write some code that features dynamic components with a C++ backend.

    Let's assume I want to write a program where:

    • The user presses a button that opens a dialogue where he fills in a name N, and position X, Y
    • When OK is pressed a component that is a rectangle with the text N from the dialogue is created at position X,Y with color C="blue"
    • N rectangles can be created by using the steps above (fully dynamic)
    • There is a C++ backed that has a list of these rectangles and can by some C++ logic change the X,Y,C properties of the rectangles or even add new rectangles or delete some created ones.

    I've read probably all documents that I could google that describe QML and C++ integration but didn't find an example that was close enough to what I need.

    I appreciate your guidelines of how to implement the desired behavior.

    Thanks in advance!
    Ben

    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