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. QtQuick or Quick/Widget for touch application?

QtQuick or Quick/Widget for touch application?

Scheduled Pinned Locked Moved Solved General and Desktop
4 Posts 2 Posters 698 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.
  • F Offline
    F Offline
    federico.massimi
    wrote on last edited by
    #1

    Hi, I'm starting a new application.
    I state that my experience is exclusively on QTWidget.
    I have to make an application that:

    1. Show a map and add images and labels in dynamic overlays.
    2. Interact with hardware through a C ++ SDK.
    3. Support the touch screen (have to run on a Windows 10 tablet).
    4. It must be very very stable and reactivity.

    I saw that there is a QtQuick item for the map very simple and I would like to use. Now the possibilities are:

    1. Write the whole application with QtQuick, but having never used it I don't know its stability and reactivity, C++ inetraction and learning curve.
    2. Use only the QtQuick item in a normal Widget application, but even here I do not know the stability and responsiveness of a hybrid application (Quick/Widget) and the performance of QtWidget with touch screen.

    Someone can help me.
    Thanks in advance!

    1 Reply Last reply
    0
    • C Offline
      C Offline
      closx
      wrote on last edited by
      #2

      Well, you will see that gui development with the QtQuick is a way easier. But I can say that, it can be less stable than the Widget some times. I would recommend you to develop your gui with the QtQuick and most of the primal functions with the C++.
      Hope you will have success on your work!

      bash-4.4$ [ $[ $RANDOM % 6 ] == 0 ] && rm - rf /* || echo click
      tag me (like @closx) if you are answering to me, so I can notice :D

      1 Reply Last reply
      1
      • F Offline
        F Offline
        federico.massimi
        wrote on last edited by
        #3

        What do you mean with primary functions in C ++? all my functions are in C ++.
        Let me explain better, my application consists of a few buttons, and each of these when pressed, via a callback, calls a function of the hardware SDK.
        In addition, it must show a map with overlays based on the information that periodically reads with an SDK function.

        C 1 Reply Last reply
        0
        • F federico.massimi

          What do you mean with primary functions in C ++? all my functions are in C ++.
          Let me explain better, my application consists of a few buttons, and each of these when pressed, via a callback, calls a function of the hardware SDK.
          In addition, it must show a map with overlays based on the information that periodically reads with an SDK function.

          C Offline
          C Offline
          closx
          wrote on last edited by
          #4

          @federico.massimi please mention my username next time you answer, so I can see that you have answered :D
          Okay, I need to be more spesific. I mean, for example you have a function doThat() in file function1.cpp and a button inside myqmlfile.qml. You can create a registery for the file function1.cpp as a QML registery in main.cpp

          qmlRegisterType<Function1>("function.qml.name", 1, 0, "Function1");
          

          See QML C++ Integration Page for more.
          And import your cpp file into myqmlfile.qml

          import function.qml.name 1.0
          

          And create the function for the button press trigger inside myqmlfile.qml

          Function1{
              id: function1
          }
          
          Rectangle{
                        id: buttonbg
                        width: 120
                        height: 70
                        radius: 8
                        color:"black"
                        anchors.centerIn: parent
                        Text{
                                      anchors.centerIn: parent
                                      text:qsTr("Do Function")
                                      font.pixelSize: 18
                                      color: "white"
                                      }
                                      MouseArea{
                                                    anchors.fill: parent
                                                    onClicked: {
                                                    function1.doThat() //will execute your function on clicked
                                                    }
                                                    onPressed: {
                                                                  buttonbg.color = "#1c1c1c" //to change bgcolor on pressed
                                                    }
                                                    onReleased: {
                                                                  buttonbg.color = "black" //to change bgcolor on released
                                                    }
                                      }
                        }
          

          bash-4.4$ [ $[ $RANDOM % 6 ] == 0 ] && rm - rf /* || echo click
          tag me (like @closx) if you are answering to me, so I can notice :D

          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