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 create multiple tabs in Central Widget of QT QMain Window
Forum Updated to NodeBB v4.3 + New Features

Can we create multiple tabs in Central Widget of QT QMain Window

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 5 Posters 1.7k Views 3 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 Enthusiast
    wrote on 13 Aug 2018, 23:24 last edited by
    #1

    Can we create multiple tabs in Central Widget of QT GUI

    R 1 Reply Last reply 14 Aug 2018, 03:45
    0
    • Q Qt Enthusiast
      13 Aug 2018, 23:24

      Can we create multiple tabs in Central Widget of QT GUI

      R Offline
      R Offline
      Ratzz
      wrote on 14 Aug 2018, 03:45 last edited by
      #2

      @Qt-Enthusiast
      Are you looking something like this http://doc.qt.io/qt-5/qstackedwidget.html ?

      --Alles ist gut.

      1 Reply Last reply
      2
      • S Offline
        S Offline
        SGaist
        Lifetime Qt Champion
        wrote on 14 Aug 2018, 22:06 last edited by
        #3

        Hi,

        Or QTabWidget ?

        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
        • Q Offline
          Q Offline
          Qt Enthusiast
          wrote on 15 Aug 2018, 01:27 last edited by
          #4

          can we make QTabWidget as central widget

          J 1 Reply Last reply 15 Aug 2018, 04:32
          0
          • Q Qt Enthusiast
            15 Aug 2018, 01:27

            can we make QTabWidget as central widget

            J Offline
            J Offline
            jsulm
            Lifetime Qt Champion
            wrote on 15 Aug 2018, 04:32 last edited by
            #5

            @Qt-Enthusiast yes

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

            1 Reply Last reply
            0
            • Q Offline
              Q Offline
              Qt Enthusiast
              wrote on 16 Aug 2018, 02:52 last edited by
              #6

              can some one share with me the application where central widget is made as QTabWidget

              R 1 Reply Last reply 16 Aug 2018, 08:24
              0
              • Q Qt Enthusiast
                16 Aug 2018, 02:52

                can some one share with me the application where central widget is made as QTabWidget

                R Offline
                R Offline
                Ratzz
                wrote on 16 Aug 2018, 08:24 last edited by
                #7

                @Qt-Enthusiast

                Take a look at Tab Dialog Example a subclass of QDialog .

                --Alles ist gut.

                1 Reply Last reply
                1
                • M Offline
                  M Offline
                  mrjj
                  Lifetime Qt Champion
                  wrote on 16 Aug 2018, 09:01 last edited by
                  #8

                  Hi
                  There is really nothing to it.

                  you can just do

                  auto tw = new QTabWidget (this);
                  tw->addTab(new QWidget, "first");
                  setCentralWidget( tw );
                  
                  1 Reply Last reply
                  3

                  1/8

                  13 Aug 2018, 23:24

                  • Login

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