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

The icon of the QCommandLinkButton does not update when the button's visibility is set to true.

    XMLWordPrintable

Details

    • Windows
    • 839d569dc (dev), fcd76f6d2 (6.10), 4b32de005 (6.9), 51f88f891 (tqtc/lts-6.8)

    Description

      The icon of the QCommandLinkButton does not update when the button's visibility is set to true.

      To reproduce the issue, run the attached example project.

      As a workaround, overriding CComandLinkButton::event(QEvent *e) fixes the issue:

       bool event(QEvent *e)
              {
              //     // if (e->type() == QEvent::StyleChange) {
              //     //     QStyleOptionButton opt;
              //     //     initStyleOption(&opt);
              //     //     setIcon(style()->standardIcon(QStyle::SP_CommandLink, &opt, this));
              //     // }
              
              
                return QPushButton::event(e);
               }
      

       

      Attachments

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

        Activity

          People

            axelspoerl Axel Spoerl
            mahdi.belila Mehdi Belila
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews