Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-61480

QTabBar::setExpanding(true) is ignored in some cases

    XMLWordPrintable

Details

    Description

      Introduced by 175f33ed855b0a8a30daafacd4f48fa3f8e76a9b.

      Code that reproduces the issue (Style::styleHint() must return Qt::AlignRight for SH_TabBar_Alignment):

      #include <QApplication>
      #include <QTabWidget>
      #include <QTabBar>
      
      int main(int argc, char *argv[])
      {
          QApplication app(argc, argv);
      
          QTabWidget tabWidget;
          for (int i = 0; i < 3; i++) {
              tabWidget.insertTab(i, new QWidget(), QString("Tab %1").arg(QString::number(i)));
          }
          tabWidget.setTabPosition(QTabWidget::North);
          tabWidget.setDocumentMode(true);
          tabWidget.tabBar()->setExpanding(true);
          tabWidget.resize(640, 480);
          tabWidget.show();
      
          return app.exec();
      }
      

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              wearyinside Oleg Yadrov
              wearyinside Oleg Yadrov
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes