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. How to really use multiproject ?
Forum Updated to NodeBB v4.3 + New Features

How to really use multiproject ?

Scheduled Pinned Locked Moved Unsolved General and Desktop
25 Posts 8 Posters 2.3k Views 6 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.
  • A Offline
    A Offline
    Anonymous_Banned275
    wrote on 7 Mar 2021, 19:58 last edited by
    #1

    After months of futzing with "stuff" I am finally at the point of real usage of QtCreator multiproject AKA "SUBDIRS"

    This is my task - for now
    My multi project consists of
    subproject examples - menus
    subproject examples - btscanner

    Each subproject works as expected

    My task is to

    open "menus" and then in "menus"
    open and run " btscanner"

    So far my subprojects have no way to "see" each other to share,
    SUBDIRS do not do much for such sharing.

    How do I implement basic C extendable philosophy in QtCreator multiproject ?

    HOW do I "include btscanner" project so it is accessible in QtCreator mutiporject scheme - initially from subproject "menus"?

    I am asking for some generic description - something to append to "SUBDIRS" scheme.

    Any suggestion would be appreciated, again in C style "include ", no details necessary :

    #include header....
    ....
    (example ) main.cpp

    This is my "SUBIRS" so far :

    SUBDIRS +=
    ../../../Qt_Projects/CAT_FT857_BT/CAT_FT857_Bluetooth_MAIN_PROJECT
    SOURCE/ORIGINAL_HCI/QT_PROJECT_CAT/CAT_V1/TEST_PROJECT.pro
    SOURCE/qtconnectivity/examples/bluetooth/btscanner #\

    P 1 Reply Last reply 9 Mar 2021, 11:37
    0
    • C Online
      C Online
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on 7 Mar 2021, 21:01 last edited by
      #2

      What has this to do with 'C++ Gurus' ? Closed!

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      J 1 Reply Last reply 8 Mar 2021, 03:37
      0
      • C Christian Ehrlicher
        7 Mar 2021, 21:01

        What has this to do with 'C++ Gurus' ? Closed!

        J Online
        J Online
        JKSH
        Moderators
        wrote on 8 Mar 2021, 03:37 last edited by
        #3

        @Christian-Ehrlicher said in How to really use multiproject ?:

        What has this to do with 'C++ Gurus' ? Closed!

        It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

        Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

        A P 2 Replies Last reply 8 Mar 2021, 17:05
        4
        • J JKSH
          8 Mar 2021, 03:37

          @Christian-Ehrlicher said in How to really use multiproject ?:

          What has this to do with 'C++ Gurus' ? Closed!

          It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

          A Offline
          A Offline
          Anonymous_Banned275
          wrote on 8 Mar 2021, 17:05 last edited by
          #4

          @JKSH said in How to really use multiproject ?:

          @Christian-Ehrlicher said in How to really use multiproject ?:

          What has this to do with 'C++ Gurus' ? Closed!

          It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

          And I am suppose to say "thank you" ?

          I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.

          But there is a moral of this
          reading and comprehending should be prerequisite before becoming a "moderator". Is it?

          But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.
          I suppose NOT locking the thread one has no clue what it is about is way too much to ask.

          Cheers
          IBTL

          J K 2 Replies Last reply 8 Mar 2021, 21:44
          0
          • A Anonymous_Banned275
            8 Mar 2021, 17:05

            @JKSH said in How to really use multiproject ?:

            @Christian-Ehrlicher said in How to really use multiproject ?:

            What has this to do with 'C++ Gurus' ? Closed!

            It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

            And I am suppose to say "thank you" ?

            I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.

            But there is a moral of this
            reading and comprehending should be prerequisite before becoming a "moderator". Is it?

            But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.
            I suppose NOT locking the thread one has no clue what it is about is way too much to ask.

            Cheers
            IBTL

            J Online
            J Online
            JKSH
            Moderators
            wrote on 8 Mar 2021, 21:44 last edited by
            #5

            @AnneRanch You have the right to raise complaints and constructive suggestions.

            You do not have the right to launch personal attacks and insults.

            Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

            1 Reply Last reply
            4
            • A Anonymous_Banned275
              8 Mar 2021, 17:05

              @JKSH said in How to really use multiproject ?:

              @Christian-Ehrlicher said in How to really use multiproject ?:

              What has this to do with 'C++ Gurus' ? Closed!

              It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

              And I am suppose to say "thank you" ?

              I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.

              But there is a moral of this
              reading and comprehending should be prerequisite before becoming a "moderator". Is it?

              But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.
              I suppose NOT locking the thread one has no clue what it is about is way too much to ask.

              Cheers
              IBTL

              K Offline
              K Offline
              kshegunov
              Moderators
              wrote on 8 Mar 2021, 23:18 last edited by
              #6

              @AnneRanch said in How to really use multiproject ?:

              And I am suppose to say "thank you" ?

              No, because the comment was not directed at you.

              I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.
              But there is a moral of this reading and comprehending should be prerequisite before becoming a "moderator". Is it?

              You know practically nothing about any of us, neither what we've read, nor what we comprehend, not what field we work in or what we know and don't know. You ain't impressing nobody by spitting bile.

              But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.

              This is a two-way street. Don't expect people to rally in support if you semi-randomly insult them.

              Read and abide by the Qt Code of Conduct

              A 1 Reply Last reply 9 Mar 2021, 01:06
              4
              • K kshegunov
                8 Mar 2021, 23:18

                @AnneRanch said in How to really use multiproject ?:

                And I am suppose to say "thank you" ?

                No, because the comment was not directed at you.

                I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.
                But there is a moral of this reading and comprehending should be prerequisite before becoming a "moderator". Is it?

                You know practically nothing about any of us, neither what we've read, nor what we comprehend, not what field we work in or what we know and don't know. You ain't impressing nobody by spitting bile.

                But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.

                This is a two-way street. Don't expect people to rally in support if you semi-randomly insult them.

                A Offline
                A Offline
                Anonymous_Banned275
                wrote on 9 Mar 2021, 01:06 last edited by
                #7

                @kshegunov said in How to really use multiproject ?:

                @AnneRanch said in How to really use multiproject ?:

                And I am suppose to say "thank you" ?

                No, because the comment was not directed at you.
                In that case -suggestion - next time send personal e-mail.

                I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.
                But there is a moral of this reading and comprehending should be prerequisite before becoming a "moderator". Is it?

                You know practically nothing about any of us, neither what we've read, nor what we comprehend, not what field we work in or what we know and don't know. You ain't impressing nobody by spitting bile.

                I generally choose whom and when to impress.

                But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.

                This is a two-way street. Don't expect people to rally in support if you semi-randomly insult them.

                Interesting ONE WAY comment.
                .
                Ever thought that I can only know about "US" only by reading the replies ?
                Are you sure I care to receive "support" from people who engage in moving my posts around and locking them ? That is childish and if you are calling my way of speaking insults I definitely do not need or want to know more about you .

                I generally do not engage in social chit chat like this. It leads nowhere and expressing personal opinion or feeling DOES NOT CHANGE nor improve anything . Some people are immune...

                Besides , that is NOT why I am here , at this forum.

                BTW still no answer to my original post

                K Pablo J. RoginaP 2 Replies Last reply 9 Mar 2021, 01:16
                0
                • A Anonymous_Banned275
                  9 Mar 2021, 01:06

                  @kshegunov said in How to really use multiproject ?:

                  @AnneRanch said in How to really use multiproject ?:

                  And I am suppose to say "thank you" ?

                  No, because the comment was not directed at you.
                  In that case -suggestion - next time send personal e-mail.

                  I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.
                  But there is a moral of this reading and comprehending should be prerequisite before becoming a "moderator". Is it?

                  You know practically nothing about any of us, neither what we've read, nor what we comprehend, not what field we work in or what we know and don't know. You ain't impressing nobody by spitting bile.

                  I generally choose whom and when to impress.

                  But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.

                  This is a two-way street. Don't expect people to rally in support if you semi-randomly insult them.

                  Interesting ONE WAY comment.
                  .
                  Ever thought that I can only know about "US" only by reading the replies ?
                  Are you sure I care to receive "support" from people who engage in moving my posts around and locking them ? That is childish and if you are calling my way of speaking insults I definitely do not need or want to know more about you .

                  I generally do not engage in social chit chat like this. It leads nowhere and expressing personal opinion or feeling DOES NOT CHANGE nor improve anything . Some people are immune...

                  Besides , that is NOT why I am here , at this forum.

                  BTW still no answer to my original post

                  K Offline
                  K Offline
                  kshegunov
                  Moderators
                  wrote on 9 Mar 2021, 01:16 last edited by
                  #8

                  Do you know @Denni-0? I imagine not. He too had decided to be a self-righteous crusader. Keep up the good work!

                  BTW still no answer to my original post

                  Intentionally.

                  Read and abide by the Qt Code of Conduct

                  1 Reply Last reply
                  3
                  • J JKSH
                    8 Mar 2021, 03:37

                    @Christian-Ehrlicher said in How to really use multiproject ?:

                    What has this to do with 'C++ Gurus' ? Closed!

                    It's a valid question about Qt Project structuring, so I've moved it to the General thread and re-opened the thread.

                    P Offline
                    P Offline
                    Pl45m4
                    wrote on 9 Mar 2021, 11:19 last edited by Pl45m4 3 Sept 2021, 11:22
                    #9

                    @JKSH

                    Btw: just realized, the down-vote button is gone... ?!
                    Not that I want to use it somewhere ;-) Just found out that it's missing


                    If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                    ~E. W. Dijkstra

                    jsulmJ 1 Reply Last reply 9 Mar 2021, 11:20
                    2
                    • P Pl45m4
                      9 Mar 2021, 11:19

                      @JKSH

                      Btw: just realized, the down-vote button is gone... ?!
                      Not that I want to use it somewhere ;-) Just found out that it's missing

                      jsulmJ Online
                      jsulmJ Online
                      jsulm
                      Lifetime Qt Champion
                      wrote on 9 Mar 2021, 11:20 last edited by
                      #10

                      @Pl45m4 Yes, it was misused sometimes.

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

                      P 1 Reply Last reply 9 Mar 2021, 11:23
                      2
                      • jsulmJ jsulm
                        9 Mar 2021, 11:20

                        @Pl45m4 Yes, it was misused sometimes.

                        P Offline
                        P Offline
                        Pl45m4
                        wrote on 9 Mar 2021, 11:23 last edited by
                        #11

                        @jsulm

                        Ah ok, I see.


                        If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                        ~E. W. Dijkstra

                        1 Reply Last reply
                        0
                        • A Anonymous_Banned275
                          7 Mar 2021, 19:58

                          After months of futzing with "stuff" I am finally at the point of real usage of QtCreator multiproject AKA "SUBDIRS"

                          This is my task - for now
                          My multi project consists of
                          subproject examples - menus
                          subproject examples - btscanner

                          Each subproject works as expected

                          My task is to

                          open "menus" and then in "menus"
                          open and run " btscanner"

                          So far my subprojects have no way to "see" each other to share,
                          SUBDIRS do not do much for such sharing.

                          How do I implement basic C extendable philosophy in QtCreator multiproject ?

                          HOW do I "include btscanner" project so it is accessible in QtCreator mutiporject scheme - initially from subproject "menus"?

                          I am asking for some generic description - something to append to "SUBDIRS" scheme.

                          Any suggestion would be appreciated, again in C style "include ", no details necessary :

                          #include header....
                          ....
                          (example ) main.cpp

                          This is my "SUBIRS" so far :

                          SUBDIRS +=
                          ../../../Qt_Projects/CAT_FT857_BT/CAT_FT857_Bluetooth_MAIN_PROJECT
                          SOURCE/ORIGINAL_HCI/QT_PROJECT_CAT/CAT_V1/TEST_PROJECT.pro
                          SOURCE/qtconnectivity/examples/bluetooth/btscanner #\

                          P Offline
                          P Offline
                          Pl45m4
                          wrote on 9 Mar 2021, 11:37 last edited by Pl45m4 3 Sept 2021, 11:39
                          #12

                          @AnneRanch

                          See this topic, esp. @t3685 's reply.
                          https://forum.qt.io/topic/58180/solved-create-top-level-qt-project-to-build-multiple-projects/10

                          Other links:

                          • https://doc.qt.io/qtcreator/creator-project-creating.html#adding-subprojects-to-projects
                          • https://doc.qt.io/qt-5/qmake-variable-reference.html#subdirs

                          If you have really huge projects with a more complex structure, it's recommended to use CMake instead of QMake.


                          If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                          ~E. W. Dijkstra

                          A 1 Reply Last reply 9 Mar 2021, 17:21
                          3
                          • A Anonymous_Banned275
                            9 Mar 2021, 01:06

                            @kshegunov said in How to really use multiproject ?:

                            @AnneRanch said in How to really use multiproject ?:

                            And I am suppose to say "thank you" ?

                            No, because the comment was not directed at you.
                            In that case -suggestion - next time send personal e-mail.

                            I wonder if there is a forum for kindergarten children where a talent of "moving boxes" would be more appreciated.
                            But there is a moral of this reading and comprehending should be prerequisite before becoming a "moderator". Is it?

                            You know practically nothing about any of us, neither what we've read, nor what we comprehend, not what field we work in or what we know and don't know. You ain't impressing nobody by spitting bile.

                            I generally choose whom and when to impress.

                            But if one cannot pass that, it is irrelevant to ask for just a tiny bit of (common) courtesy before post is monkeyed around with.

                            This is a two-way street. Don't expect people to rally in support if you semi-randomly insult them.

                            Interesting ONE WAY comment.
                            .
                            Ever thought that I can only know about "US" only by reading the replies ?
                            Are you sure I care to receive "support" from people who engage in moving my posts around and locking them ? That is childish and if you are calling my way of speaking insults I definitely do not need or want to know more about you .

                            I generally do not engage in social chit chat like this. It leads nowhere and expressing personal opinion or feeling DOES NOT CHANGE nor improve anything . Some people are immune...

                            Besides , that is NOT why I am here , at this forum.

                            BTW still no answer to my original post

                            Pablo J. RoginaP Offline
                            Pablo J. RoginaP Offline
                            Pablo J. Rogina
                            wrote on 9 Mar 2021, 16:36 last edited by
                            #13

                            @AnneRanch said in How to really use multiproject ?:

                            BTW still no answer to my original post

                            Based on the way you behaved in this post, I'd bet the answer is going to take a long time...

                            Upvote the answer(s) that helped you solve the issue
                            Use "Topic Tools" button to mark your post as Solved
                            Add screenshots via postimage.org
                            Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                            1 Reply Last reply
                            1
                            • P Pl45m4
                              9 Mar 2021, 11:37

                              @AnneRanch

                              See this topic, esp. @t3685 's reply.
                              https://forum.qt.io/topic/58180/solved-create-top-level-qt-project-to-build-multiple-projects/10

                              Other links:

                              • https://doc.qt.io/qtcreator/creator-project-creating.html#adding-subprojects-to-projects
                              • https://doc.qt.io/qt-5/qmake-variable-reference.html#subdirs

                              If you have really huge projects with a more complex structure, it's recommended to use CMake instead of QMake.

                              A Offline
                              A Offline
                              Anonymous_Banned275
                              wrote on 9 Mar 2021, 17:21 last edited by
                              #14

                              @Pl45m4 said in How to really use multiproject ?:

                              @AnneRanch

                              See this topic, esp. @t3685 's reply.
                              https://forum.qt.io/topic/58180/solved-create-top-level-qt-project-to-build-multiple-projects/10

                              Other links:

                              • https://doc.qt.io/qtcreator/creator-project-creating.html#adding-subprojects-to-projects
                              • https://doc.qt.io/qt-5/qmake-variable-reference.html#subdirs

                              If you have really huge projects with a more complex structure, it's recommended to use CMake instead of QMake.

                              Another post recently linked back to this one, so I wanted to augment this with a couple more relevant links for setting up a manageable, maintainable qmake SUBDIRS structure:

                              https://www.toptal.com/qt/vital-guide-qmake

                              https://wiki.qt.io/QMake-top-level-srcdir-and-builddir

                              Which helped me set up a working example: https://github.com/219-design/qt-qml-project-template-with-ci/blob/6af6488d74e1dc97a/main_gui.pro

                              The above is the "closest" example of implementing "SUBDIRS" with "main project" , but it is little too complex to gain understanding how to implement such setting.

                              Most examples / tutorials are about the concept of "SUBDIRS" . In my interpretation the "SUBDIRS" is basically way to manage independent projects, sort off "under one roof".
                              However to actually run such scheme is another and still unclear story.

                              Looks as intimate understanding of "make" would help.
                              Maybe the answer is in ".depends" setting of the main .pro.
                              Cheers

                              1 Reply Last reply
                              0
                              • A Offline
                                A Offline
                                Anonymous_Banned275
                                wrote on 9 Mar 2021, 19:00 last edited by
                                #15

                                This is a REAL C question , but since the discussion is now here I am posting it here.

                                Update:
                                As of now my main project is "example MDI".
                                So I am taking this route hoping to find a solution to the issue.
                                It is sort of "do not reinvent the wheel" approach.

                                The MDI example has the attached piece of code which uses QApplication to show text dialog. The link to QApplicatio is still under investigation - all I know it is "external" to "MDI project ".

                                I figure if I can actually trace the code flow all the way to the message text I could replicate similar approach and replace QApplication with btscanner.

                                I need assistance with

                                1. How do I trace / debug all the way to the QApplication source code (?) which contains the message text ? I am presently stuck at the aboutQt function.
                                2. Am I on right track to trace the "addAction" call or is not going to help with btscanner ? ( I feel my current approach is sort of "starting in the middle ". )

                                Code snippet from "MDI example"

                                QAction *aboutQtAct = helpMenu->addAction(tr("About &Qt (link to other projets?) "),
                                         qApp, &QApplication::aboutQt); // shows text dialog "about Qt " 
                                aboutQtAct->setStatusTip(tr("Show the Qt library's About box"));
                                
                                1 Reply Last reply
                                0
                                • A Offline
                                  A Offline
                                  Anonymous_Banned275
                                  wrote on 11 Mar 2021, 02:37 last edited by
                                  #16

                                  I will back-off a little.
                                  Can somebody explain (to me ) why the SUBDIRS "directories " AKA independent programs has to be "in sequence "?

                                  Each program basically follow the Qt "Application" scheme - from TEMPLATE to TARGET.

                                  So far I have not found how these dependent programs - each one with its own "main" and QApplication "callback / event" loop can run as one program.
                                  Logically there should be one and only one "main " and its callback / event loop.
                                  Maybe the idea of independent programs supporting ONE main program is bogus. Perhaps there should be ONE main program supported by libraries , not independent programs. (Similar scheme works perfect in another IDE - BUT it has no GUI nor events support !) .
                                  Then the whole scheme of SUBDIRS as "independent programs" is wrong.

                                  J 1 Reply Last reply 11 Mar 2021, 07:19
                                  0
                                  • A Anonymous_Banned275
                                    11 Mar 2021, 02:37

                                    I will back-off a little.
                                    Can somebody explain (to me ) why the SUBDIRS "directories " AKA independent programs has to be "in sequence "?

                                    Each program basically follow the Qt "Application" scheme - from TEMPLATE to TARGET.

                                    So far I have not found how these dependent programs - each one with its own "main" and QApplication "callback / event" loop can run as one program.
                                    Logically there should be one and only one "main " and its callback / event loop.
                                    Maybe the idea of independent programs supporting ONE main program is bogus. Perhaps there should be ONE main program supported by libraries , not independent programs. (Similar scheme works perfect in another IDE - BUT it has no GUI nor events support !) .
                                    Then the whole scheme of SUBDIRS as "independent programs" is wrong.

                                    J Online
                                    J Online
                                    JKSH
                                    Moderators
                                    wrote on 11 Mar 2021, 07:19 last edited by
                                    #17

                                    @AnneRanch said in How to really use multiproject ?:

                                    Logically there should be one and only one "main " and its callback / event loop.
                                    Maybe the idea of independent programs supporting ONE main program is bogus. Perhaps there should be ONE main program supported by libraries , not independent programs....

                                    Then the whole scheme of SUBDIRS as "independent programs" is wrong.

                                    This is correct.

                                    SUBDIRS is for grouping one or more libraries with one application (or no application)

                                    I have not found how these dependent programs - each one with its own "main" and QApplication "callback / event" loop can run as one program.

                                    This is impossible. You cannot have multiple main() and QApplication instances in the same program.

                                    Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                                    A 1 Reply Last reply 11 Mar 2021, 14:32
                                    2
                                    • J JKSH
                                      11 Mar 2021, 07:19

                                      @AnneRanch said in How to really use multiproject ?:

                                      Logically there should be one and only one "main " and its callback / event loop.
                                      Maybe the idea of independent programs supporting ONE main program is bogus. Perhaps there should be ONE main program supported by libraries , not independent programs....

                                      Then the whole scheme of SUBDIRS as "independent programs" is wrong.

                                      This is correct.

                                      SUBDIRS is for grouping one or more libraries with one application (or no application)

                                      I have not found how these dependent programs - each one with its own "main" and QApplication "callback / event" loop can run as one program.

                                      This is impossible. You cannot have multiple main() and QApplication instances in the same program.

                                      A Offline
                                      A Offline
                                      Anonymous_Banned275
                                      wrote on 11 Mar 2021, 14:32 last edited by
                                      #18

                                      @JKSH
                                      So it is back to terminology or semantics.

                                      "project" as used in Qt terminology, especially in "SUBDIRS" scheme is not necessarily code build as a stand alone functioning application.

                                      "library" on the other hand is build / complied as a code to be used to support a "project". Library is NOT standalone functioning application.

                                      With that in mind - SUBDIRS options to "add new project " or add "existing projects " is grossly misleading.

                                      However, the example "MDI" application APPEARS to combine Qt standard QApplication "app" with a reference to another "QApplication " qapp.

                                      Unfortunately this software trick is documented nowhere.
                                      But for sure - "MDI" example source code is nowhere near "SUBDIRS" scheme.

                                      So for time being I am looking into replacing "MDI" QApplication qapp with QApplication "btscaner_app" ( no "main" event loop ) as used in "MDI" example .

                                      Does this makes any sense ?

                                      J P 2 Replies Last reply 11 Mar 2021, 14:58
                                      0
                                      • A Anonymous_Banned275
                                        11 Mar 2021, 14:32

                                        @JKSH
                                        So it is back to terminology or semantics.

                                        "project" as used in Qt terminology, especially in "SUBDIRS" scheme is not necessarily code build as a stand alone functioning application.

                                        "library" on the other hand is build / complied as a code to be used to support a "project". Library is NOT standalone functioning application.

                                        With that in mind - SUBDIRS options to "add new project " or add "existing projects " is grossly misleading.

                                        However, the example "MDI" application APPEARS to combine Qt standard QApplication "app" with a reference to another "QApplication " qapp.

                                        Unfortunately this software trick is documented nowhere.
                                        But for sure - "MDI" example source code is nowhere near "SUBDIRS" scheme.

                                        So for time being I am looking into replacing "MDI" QApplication qapp with QApplication "btscaner_app" ( no "main" event loop ) as used in "MDI" example .

                                        Does this makes any sense ?

                                        J Online
                                        J Online
                                        JKSH
                                        Moderators
                                        wrote on 11 Mar 2021, 14:58 last edited by
                                        #19

                                        @AnneRanch said in How to really use multiproject ?:

                                        "project" as used in Qt terminology, especially in "SUBDIRS" scheme is not necessarily code build as a stand alone functioning application.

                                        Correct. "Project" is a broad term. For example, you can have an "application project" (which lets you build a standalone functioning application) or a "library project" (which lets you build a library).

                                        Here are some different types of projects: https://doc.qt.io/qt-5//qmake-common-projects.html

                                        Library is NOT standalone functioning application.

                                        Correct. And this is not Qt-specific: The word "library" means something quite specific to programmers, no matter what programming language they use: https://en.wikipedia.org/wiki/Library_(computing)

                                        • Qt is a collection of libraries
                                        • Qt Creator is a standalone functioning application

                                        With that in mind - SUBDIRS options to "add new project " or add "existing projects " is grossly misleading.

                                        How so? For example, I can add 1 application project and 3 library projects to my SUBDIRS project. What's misleading about that?

                                        However, the example "MDI" application APPEARS to combine Qt standard QApplication "app" with a reference to another "QApplication " qapp.

                                        Sorry, I don't understand what you mean. Can you please elaborate?

                                        Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                                        1 Reply Last reply
                                        2
                                        • A Anonymous_Banned275
                                          11 Mar 2021, 14:32

                                          @JKSH
                                          So it is back to terminology or semantics.

                                          "project" as used in Qt terminology, especially in "SUBDIRS" scheme is not necessarily code build as a stand alone functioning application.

                                          "library" on the other hand is build / complied as a code to be used to support a "project". Library is NOT standalone functioning application.

                                          With that in mind - SUBDIRS options to "add new project " or add "existing projects " is grossly misleading.

                                          However, the example "MDI" application APPEARS to combine Qt standard QApplication "app" with a reference to another "QApplication " qapp.

                                          Unfortunately this software trick is documented nowhere.
                                          But for sure - "MDI" example source code is nowhere near "SUBDIRS" scheme.

                                          So for time being I am looking into replacing "MDI" QApplication qapp with QApplication "btscaner_app" ( no "main" event loop ) as used in "MDI" example .

                                          Does this makes any sense ?

                                          P Offline
                                          P Offline
                                          Pl45m4
                                          wrote on 11 Mar 2021, 16:01 last edited by
                                          #20

                                          @AnneRanch said in How to really use multiproject ?:

                                          However, the example "MDI" application APPEARS to combine Qt standard QApplication "app" with a reference to another "QApplication " qapp.

                                          Are you confused because of QApplication and QCoreApplicaton?

                                              QApplication app(argc, argv);
                                              QCoreApplication::setApplicationName("MDI Example");
                                              QCoreApplication::setOrganizationName("QtProject");
                                              QCoreApplication::setApplicationVersion(QT_VERSION_STR);
                                          

                                          (https://code.qt.io/cgit/qt/qtbase.git/tree/examples/widgets/mainwindows/mdi/main.cpp?h=5.15#n61)

                                          It's the same, just a bit further down in inheritance tree...
                                          If you look at this, you can see that

                                          • QApplication inherits
                                            • QGuiApplication which inherits
                                              • QCoreApplication

                                          (bottom to top)

                                          So it's still the same instance of qApp.


                                          If debugging is the process of removing software bugs, then programming must be the process of putting them in.

                                          ~E. W. Dijkstra

                                          1 Reply Last reply
                                          1

                                          1/25

                                          7 Mar 2021, 19:58

                                          • Login

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