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

Radiobuttons can get unchecked (toggle) even though being exclusive, due to another sibling groupbox with own radiobuttons

    XMLWordPrintable

Details

    • Windows

    Description

      When two radiobuttons shares the same parent and has a sibling groupbox with its own radiobuttons as childrens then the top level radiobuttons gets toggle-able, meaning that they can get unchecked both of them when they shouldn't. All radioButtons are set to be exclusive.

      Basically when clicking on RadioButton 1 or 2 when the one you click on is already checked, it becomes unchecked. So the state would becomes of two unchecked RadioButtons in the same group.

       

      -GroupBox1
         |-RadioButton1 (Child of GroupBox 1)

         |-RadioButton2 (Child of GroupBox 1)

         |-GroupBox2 (Child of GroupBox 1)

            |-RadioButton3  (Child of GroupBox 2)

            |-RadioButton4 (Child of GroupBox 2)

       

      RadioButton 1 and 2 are set to be exclusive so only one can be checked at the same time but are toggle-able so that both can be unchecked.

      RadioButton 3 and 4 works as intended, are also set to be exclusive.

      RadioButton 1 and 2 does not effect RadioButton 3 and 4, nor does RadioButton 3 and 4 effect RadioButton 1 and 2.

       

      The workaround is to not use nested groupboxes.

      Attachments

        1. main.cpp
          0.2 kB
          Aji Daleni
        2. mainwindow.cpp
          0.2 kB
          Aji Daleni
        3. mainwindow.h
          0.3 kB
          Aji Daleni
        4. mainwindow.ui
          3 kB
          Aji Daleni
        5. untitled1.pro
          1 kB
          Aji Daleni
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            srutledg Shawn Rutledge
            fh Aji Daleni
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes