Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. can we access private qinvokable and qproperty into qml ?
Forum Updated to NodeBB v4.3 + New Features

can we access private qinvokable and qproperty into qml ?

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 3 Posters 362 Views 2 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.
  • Q Offline
    Q Offline
    Qt embedded developer
    wrote on last edited by
    #1

    i want to know can we access private Q_INVOKABLE function and Q_PROPERTY into qml ?

    sierdzioS 1 Reply Last reply
    1
    • Q Qt embedded developer

      i want to know can we access private Q_INVOKABLE function and Q_PROPERTY into qml ?

      sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      Yes, QML (and other meta-object methods) will see Q_INVOKABLE and Q_PROPERTY even if they are declared private.

      (Z(:^

      1 Reply Last reply
      2
      • Q Qt embedded developer has marked this topic as solved on
      • KH-219DesignK Offline
        KH-219DesignK Offline
        KH-219Design
        wrote on last edited by
        #3

        I agree with @sierdzio , and I just want to add that several years ago I got curious about why and how the private data-members are visible to QML. What I discovered was posted to stackoverflow (shared here for the curious): https://stackoverflow.com/a/56694238/10278

        www.219design.com
        Software | Electrical | Mechanical | Product Design

        1 Reply Last reply
        2

        • Login

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