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

[REG]: styleSheet() does not work good with QRadialGradient.

    XMLWordPrintable

Details

    Description

      When an style sheet with QRadialGradient is applied on QMainWindow, background of the window becomes black and leaves some strange artifacts.

      This looks good with 4.4.3 but not with 4.5.x

      It can be reproduce with following style:

      #include <QtGui>
      class myWindow :public QMainWindow
      {
      public:
          myWindow ()
          {
              setStyleSheet("QMainWindow {background: qradialgradient(spread:pad, cx:0.9, cy:0.12, radius:0.5, fx:0.93, fy:0.07, stop:0 rgba(0, 92, 169, 255), stop:0.3 rgba(0, 92, 169, 255), stop:0.5 rgba(0, 92, 169, 80), stop:0.6 rgba(0, 92, 169, 30), stop:1 rgba(0, 92, 169, 0))}");
           }
         };
      
      int main(int argc, char *argv[])
      {
          QApplication app(argc, argv);
          myWindow* mw = new myWindow();
          mw->show();    
          return app.exec();
      }
      

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            smk smk
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes