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

CellWidgets does not scroll in QTableVidget with stylesheet

    XMLWordPrintable

Details

    • Bug
    • Resolution: Cannot Reproduce
    • Not Evaluated
    • 5.3.0
    • 4.8.0
    • None
    • Mac OSX Lion (10.7)

    Description

      The sample application (code below) does not scroll the items in the table - but if the background-color stylesheet property is not used, then everything works fine.
      This happens only on OSX, the same code on Windows works correctly

      #include <QApplication>
      #include <QPushButton>
      #include <QTableWidget>

      int main(int argc, char *argv[]) {
      QApplication app(argc, argv);

      QTableWidget *testtable = new QTableWidget();

      testtable->setRowCount(100);
      testtable->setColumnCount(1);
      testtable->setStyleSheet("QTableWidget

      { background-color: red; }

      ");
      for(int i = 0 ; i < 100 ; i ++)

      { testtable->setCellWidget( i, 0, new QPushButton( QString("TEST ") + QString().setNum(i+1) ) ); }

      testtable->show();
      return app.exec();
      return EXIT_SUCCESS;
      }

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            cstamas Csomos Tamas
            Votes:
            6 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes