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

Disable + checked QRadioButton in a buttongroup

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P3: Somewhat important
    • None
    • 5.8.0
    • None

    Description

      Try the below code:

       

      int main(int argc, char *argv[]) {
       QApplication app(argc, argv);
      
       QWidget *widget = new QWidget;
       QVBoxLayout layout;
       widget->setLayout(&layout);
      
       QRadioButton* b1 = new QRadioButton("RADIOBUTTON1", widget);
       QRadioButton* interested = new QRadioButton("RADIOBUTTON2", widget);
       QRadioButton* b3 = new QRadioButton("RADIOBUTTON3", widget);
      
       interested->setDisabled(true);
       interested->setChecked(true);
      
       layout.addWidget(b1);
       layout.addWidget(interested);
       layout.addWidget(b3);
       widget->show();
      
       return app.exec();
      }
      

       

      If we click one of the buttons the interested button get unchecked! which is a disable button.

      Should it happen ?

      Attachments

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

        Activity

          People

            richard Richard Moe Gustavsen
            iman4k Im@n4K ahm
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes