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

Style sheet: When style sheet get applied on a Dialog button box with hidden buttons, buttons are displayed.

    XMLWordPrintable

Details

    Description

      Style sheet: When style sheet get applied on a Dialog button box with hidden buttons, buttons are displayed.

      #include <QtGui>
      
      int main(int argc, char *argv[])
      {
          QApplication a(argc, argv);
          QDialog dialog;
          
          QHBoxLayout *buttons = new QHBoxLayout(&dialog);
          QDialogButtonBox * buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel);
          buttons->addWidget(buttonBox);
          buttonBox->button(QDialogButtonBox::Ok)->setVisible(false);
          a.setStyleSheet("/* */");
          qDebug() << buttonBox->button(QDialogButtonBox::Ok)->isVisible();
          dialog.show();
          qDebug() << buttonBox->button(QDialogButtonBox::Ok)->isVisible();
          return dialog.exec();
      }
      

      Attachments

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

        Activity

          People

            goffart Olivier Goffart (closed Nokia identity) (Inactive)
            engvolds Morten Engvoldsen (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes