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. QTabWidget does not accept QHelpEngine's central widget
Forum Updated to NodeBB v4.3 + New Features

QTabWidget does not accept QHelpEngine's central widget

Scheduled Pinned Locked Moved Solved General and Desktop
8 Posts 2 Posters 1.0k 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.
  • D Offline
    D Offline
    dalishi
    wrote on last edited by dalishi
    #1

    Hi I'm following this link to embed help file into my app. The QTabWidget::addTab does not accept the QHelpContentWidget * helpEngine->contentWidget() and QHelpIndexWidget *.

    QTabWidget* tWidget = new QTabWidget;
    tWidget->setMaximumWidth(200);
    tWidget->addTab(helpEngine->contentWidget(), "Contents");
    tWidget->addTab(helpEngine->indexWidget(), "Index");
    
     error: no matching function for call to ‘QTabWidget::addTab(QHelpIndexWidget*, const char [6])’
         tabWidget->addTab(helpEngine->indexWidget(), "Index");
                                                                 ^
    
    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Are you missing the include for QHelpContentWidget ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      D 1 Reply Last reply
      1
      • SGaistS SGaist

        Hi,

        Are you missing the include for QHelpContentWidget ?

        D Offline
        D Offline
        dalishi
        wrote on last edited by dalishi
        #3

        @SGaist said in QTabWidget does not accept QHelpEngine's central widget:

        Hi,

        Are you missing the include for QHelpContentWidget ?

        @SGaist Thanks. And I was being fool to forget this. A little surprised though that the <QHelpEngine> does not include <QHelpContentWidget> and <QHelpIndexWidget>.

        SGaistS 1 Reply Last reply
        0
        • D dalishi

          @SGaist said in QTabWidget does not accept QHelpEngine's central widget:

          Hi,

          Are you missing the include for QHelpContentWidget ?

          @SGaist Thanks. And I was being fool to forget this. A little surprised though that the <QHelpEngine> does not include <QHelpContentWidget> and <QHelpIndexWidget>.

          SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @dalishi said in QTabWidget does not accept QHelpEngine's central widget:

          A little surprised though that the <QHelpEngine> does not include <QHelpContentWidget> and <QHelpIndexWidget>.

          There's no reason for that, the engine can be used without these two widget classes.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          D 1 Reply Last reply
          1
          • SGaistS SGaist

            @dalishi said in QTabWidget does not accept QHelpEngine's central widget:

            A little surprised though that the <QHelpEngine> does not include <QHelpContentWidget> and <QHelpIndexWidget>.

            There's no reason for that, the engine can be used without these two widget classes.

            D Offline
            D Offline
            dalishi
            wrote on last edited by dalishi
            #5

            @SGaist said in QTabWidget does not accept QHelpEngine's central widget:

            @dalishi said in QTabWidget does not accept QHelpEngine's central widget:

            A little surprised though that the <QHelpEngine> does not include <QHelpContentWidget> and <QHelpIndexWidget>.

            There's no reason for that, the engine can be used without these two widget classes.

            Hi @SGaist Thanks for the reply. Now I get the QHelpEngine worked in my application with a .qch and .qhc.
            However, when I try to statically link my application to Qt (which i build myself), using

            ~/qt5-static-build/qtbase/bin/qmake -config release ..
            

            there's an error:

            Project ERROR: Unknown module(s) in QT: help
            

            I found the libQt5Help.a is under /qttools/lib/ while other main modules like libQt5Gui are in /qtbase/lib/.
            Do I need to specially indicate where to find the library? I have Qt += help in my .pro file.

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Looks like it didn't get installed. You can call make install in the module build folder and see if it fixes that.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              D 1 Reply Last reply
              0
              • SGaistS SGaist

                Looks like it didn't get installed. You can call make install in the module build folder and see if it fixes that.

                D Offline
                D Offline
                dalishi
                wrote on last edited by
                #7

                @SGaist said in QTabWidget does not accept QHelpEngine's central widget:

                Looks like it didn't get installed. You can call make install in the module build folder and see if it fixes that.

                Hi @SGaist Thanks. This topic is resolved.

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  Great !

                  Then please mark the thread as solved using the "Topic Tools" button so that other forum users may know a solution has been found :)

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  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