Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Enabling Qt into an Android native App already developed without Qt
Forum Updated to NodeBB v4.3 + New Features

Enabling Qt into an Android native App already developed without Qt

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
7 Posts 2 Posters 1.6k Views 4 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.
  • G Offline
    G Offline
    gianpierop
    wrote on last edited by gianpierop
    #1

    Hi all, I'm new and I never used Qt. I received a Qt script and I have native code of an Android App. Is it possible to integrate this Qt script into native code of Android App? Or do I have to create a new Android App from scratch in order to use Qt? Could you please link me some tutorials to get started into this direction (use Qt script into an Android App already developed without QT support). Thank you a lot

    jsulmJ 1 Reply Last reply
    0
    • G gianpierop

      Hi all, I'm new and I never used Qt. I received a Qt script and I have native code of an Android App. Is it possible to integrate this Qt script into native code of Android App? Or do I have to create a new Android App from scratch in order to use Qt? Could you please link me some tutorials to get started into this direction (use Qt script into an Android App already developed without QT support). Thank you a lot

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @gianpierop What do you mean by "Qt script"? Do you mean you have some C++ code using Qt? Or QML?

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • G Offline
        G Offline
        gianpierop
        wrote on last edited by gianpierop
        #3

        Sorry. You're right. In general that's C++ implementation with Qt Framework. I said script because there are also javascripts interpreted by Qt. But my idea is general.

        In other words, can I integrate a Qt interpreter and C++ source code into an existing native source code App? Then I'd like to instantiate a C++ / Qt class and invoke some method from the java source code of my android app.

        jsulmJ 1 Reply Last reply
        0
        • G gianpierop

          Sorry. You're right. In general that's C++ implementation with Qt Framework. I said script because there are also javascripts interpreted by Qt. But my idea is general.

          In other words, can I integrate a Qt interpreter and C++ source code into an existing native source code App? Then I'd like to instantiate a C++ / Qt class and invoke some method from the java source code of my android app.

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @gianpierop I'm not a Java expert, but as far as I know you can call C++ from Java. So, it should be possible.

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          G 1 Reply Last reply
          0
          • jsulmJ jsulm

            @gianpierop I'm not a Java expert, but as far as I know you can call C++ from Java. So, it should be possible.

            G Offline
            G Offline
            gianpierop
            wrote on last edited by
            #5

            @jsulm Yes, what you say is called native calls, but it depends on the Operating System. However in this case the C++ code is written within the Qt Framework and I guess that I have to put some .so objects and some configuration in order to make the app working, is it true? And if this is the case, is it possible to add Qt dependencies into an App already created without Qt dependencies?
            Regards.
            Gianpiero

            jsulmJ 1 Reply Last reply
            0
            • G gianpierop

              @jsulm Yes, what you say is called native calls, but it depends on the Operating System. However in this case the C++ code is written within the Qt Framework and I guess that I have to put some .so objects and some configuration in order to make the app working, is it true? And if this is the case, is it possible to add Qt dependencies into an App already created without Qt dependencies?
              Regards.
              Gianpiero

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @gianpierop You will need to add Qt libraries used in your C++ code. And you will most probably need to start the Qt event loop (usually done by calling QApplication app; app.exec();). How to add libraries to your Android app depends on what tools/build system you use. I'm not an expert here.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              G 1 Reply Last reply
              0
              • jsulmJ jsulm

                @gianpierop You will need to add Qt libraries used in your C++ code. And you will most probably need to start the Qt event loop (usually done by calling QApplication app; app.exec();). How to add libraries to your Android app depends on what tools/build system you use. I'm not an expert here.

                G Offline
                G Offline
                gianpierop
                wrote on last edited by
                #7

                @jsulm Thank you for your first hints and for telling me it can do: so is not stupid if I start to study some Qt tutorials in order to understand what I have to do.

                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