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

Major REG [5.12.4 -> 5.15.0] Stylesheets ruins buttons (on Mac)

    XMLWordPrintable

Details

    • macOS
    • a9f82b8b2c19ecc5bf5ab0d376780c34e8435202

    Description

      It appears to ruin more than just QMessageBoxes, but a simple example is the following (causing the messagebox not to respond on clicks)

      int main(int argc, char *argv[])
      {
        QApplication a(argc, argv);
        QString styleSheet = QStringLiteral(
              " QWidget { "
              "   background: #ebebeb;"
              " } "); 
        a.setStyleSheet(styleSheet);
        const QString msg = QStringLiteral("This does not work");
        QMessageBox::information(nullptr, QStringLiteral(""), msg);
      }
      

      I have attached an example for completeness (preventing user program exit)
      Setting "background" in a stylesheet appears to be central to trigger the bug.

      Attachments

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

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            tmartsum Thorbjørn Lund Martsum
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes